about summary refs log tree commit diff
path: root/src/comp/middle/trans_objects.rs
AgeCommit message (Collapse)AuthorLines
2012-01-13Obj system? What obj system?Marijn Haverbeke-951/+0
Removes the obj system from the compiler. Closes #1484
2012-01-12Make driver::session::session no longer an objectMarijn Haverbeke-0/+2
Rather, it is now a struct where properties like opts are accessed directly, and the error-reporting methods are part of a static impl (with the same name as the type).
2012-01-03More work on translating dictionary-passingMarijn Haverbeke-1/+1
Reached a point where simple uses of interfaces without bounds work. Issue #1227
2012-01-02Pass bounds to trans::type_of_fnMarijn Haverbeke-3/+5
2011-12-23Use the same type of record in ty::ty_fn and ty::methodMarijn Haverbeke-11/+12
Removes some more code duplication.
2011-12-22Unify some data structures in syntax::ast that were doing the same thingMarijn Haverbeke-11/+11
As a preparation to removing some duplication in typeck.
2011-12-18Only look for a matching method when normal field access failsMarijn Haverbeke-2/+2
We should probalby warn when defining a method foo on {foo: int} etc. This should reduce the amount of useless typevars that are allocated. Issue #1227
2011-12-16reorder args to the various vec, option fns so blk comes lastNiko Matsakis-3/+3
2011-12-16Make uses of self in impls compileMarijn Haverbeke-2/+2
Get rid of expr_self_call, introduces def_self. `self` is now, syntactically, simply a variable. A method implicitly brings a `self` binding into scope. Issue #1227
2011-12-13Copy first batch of material from libstd to libcore.Graydon Hoare-1/+1
2011-11-23Rollback return-by-referenceMarijn Haverbeke-4/+2
It's proving too inflexible, so I'm ripping out the extra complexity in the hope that regions will, at some point, provide something similar. Closes #918
2011-11-18Make tag, resource and object constructors take their arguments by copyMarijn Haverbeke-14/+5
Doing something like some([1, 2, 3]) will now no longer create a temporary copy of the vector. It will also be easier for the kind checker to see that putting a resource into a data-structure constructor is safe.
2011-11-17remove compile-command from local variable blocksNiko Matsakis-1/+0
2011-11-10Cleanup unused importsHaitao Li-1/+1
2011-11-03Disallow writing to function arguments againMarijn Haverbeke-1/+2
Remove implicit copying hack. Closes #1118
2011-11-02thread the context through so that int can be 64 bits on x86_64Niko Matsakis-17/+17
2011-10-21Drop support for iter, put, and for-eachMarijn Haverbeke-7/+4
Closes #1056
2011-10-20Merge ast::proto_shared and ast::proto_closureBrian Anderson-1/+2
Now they are both just proto_shared and proto_shared takes an argument indicating that it is sugared as 'lambda'
2011-10-20Rename ast::proto_fn to ast::proto_sharedBrian Anderson-1/+1
2011-10-20Get rid of taskpointer-passing throughout the compilerMarijn Haverbeke-5/+4
Only intrinsics still take a dummy taskptr. We'll have to do some makefile stunts to snapshot a version without taskptrs-in-intrinsics. Issue #466
2011-10-14Use trans_expr_save_in instead of trans_expr when appropriateMarijn Haverbeke-1/+1
This guards against passing a save_in destination to nil or bot-typed things.
2011-10-13Make trans_anon_obj properly thread its bcxMarijn Haverbeke-9/+3
Closes #893 Unfortunately, anon objs are still so broken as to be useless (fields don't work).
2011-10-12reimplement some of the unsafe stuff which got lostNiko Matsakis-2/+2
- blocks inherit unsafety - remove the --check-unsafe flag - add unsafe annotations where needed to get things to compile
2011-10-12continue to annotate trans functions as unsafe where neccessaryNiko Matsakis-3/+3
2011-10-07Make it possible to have locals that don't live on the stackMarijn Haverbeke-1/+4
Local values that are not mutated, don't need to be cleaned up, and are immediate, don't need to be spilled. (All immediate args, and non-pointer immediate let locals.)
2011-10-07Parse and typecheck by-value and by-ref arg specsMarijn Haverbeke-2/+3
Add sprinkle && throughout the compiler to make it typecheck again. Issue #1008
2011-10-05Add trans_temp_expr for what used to be trans_expr, rename t_e_dps to trans_exprMarijn Haverbeke-3/+3
Issue #667
2011-10-05Revert "Revert "Get rid of 'overwrite' destination kind""Marijn Haverbeke-1/+1
This reverts commit ce9e0fc94f4a74594e7b342d128b3713b53ef0d7.
2011-10-04Revert "Get rid of 'overwrite' destination kind"Patrick Walton-1/+1
This reverts commit 6e652588bfb3edea298026f56648057677b0fa3f.
2011-10-04Get rid of 'overwrite' destination kindMarijn Haverbeke-1/+1
It wasn't safe (computing the rval might invalidate the lval addr), and needlessly complicating things (code was already building up intermediary results to work around other unsafeties). Issue #667
2011-09-29Move last remaining expression types out of trans_exprMarijn Haverbeke-32/+22
Issue #667
2011-09-28rustc: Switch to cdecl for all calls. This is needed to make stack growth ↵Patrick Walton-5/+4
efficient, as I need to use eax and ecx in the function prologue and can't afford to stomp on incoming arguments.
2011-09-24Small refactors.Lindsey Kuper-34/+26
Factor out some shared code from the start of process_fwding_mthd and process_bkwding_mthd; get rid of unneeded temp variable.
2011-09-23Make sure no dynamic allocas are used before they are allocatedMarijn Haverbeke-1/+1
Closes #965
2011-09-22rustc: Write raw type parameters instead of linearized type parameters in ↵Patrick Walton-6/+12
object body shapes
2011-09-17Add a precondition to GEP_tup_likeTim Chevalier-0/+16
2011-09-16Add non_ty_var precondition for type_of_fn, plus minor cleanupTim Chevalier-4/+4
2011-09-15Added non_ty_var precondition to trans::type_of_innerTim Chevalier-6/+16
This allows us to legitimately call unreachable() in the ty_var case.
2011-09-14Add syntax and representation for return-by-mutably-rooted-refMarijn Haverbeke-2/+2
This will be used in the near future to decide what can safely be done with the returned reference. Issue #918
2011-09-14Add support for basic return-by-alias to transMarijn Haverbeke-5/+5
Issue #918
2011-09-14Clean up trans_obj.rs a bitMarijn Haverbeke-30/+21
As a preparation to adding an arg to type_of_fn_full
2011-09-12Factor imports mindlessly.Graydon Hoare-15/+8
2011-09-12Reformat for new mode syntax, step 1Marijn Haverbeke-26/+24
Long lines were fixed in a very crude way, as I'll be following up with another reformat in a bit.
2011-09-12Make the names of the arg mode tag reflect their (revised) meaningMarijn Haverbeke-11/+3
2011-09-12Pass all arguments by reference, make immut alias mode equiv to valueMarijn Haverbeke-1/+1
Arguments that can't be safely referenced will be implicitly copied. (Warnings for expensive copies will be forthcoming.) This will allow us to get rid of most of the ampersands in function signatures. See [1]. [1] https://mail.mozilla.org/pipermail/rust-dev/2011-September/000759.html
2011-09-02Reformat. Issue #855Brian Anderson-54/+42
2011-09-02Add a constraint to trans::type_ofTim Chevalier-1/+6
trans::type_of now has a constraint saying that its type argument is statically sized. This eliminates the "impossible happened" case in type_of. Yay! I note that this change decreased translation time for stage2/rustc from 16.1 s to 14.0 s. I also think many of the remaining checks could be eliminated with some mildly clever use of constrained types and further preconditions. Future work!
2011-09-01Rename std::istr to std::str. Issue #855Brian Anderson-8/+8
2011-09-01Remove std::str. Issue #855Brian Anderson-1/+0
2011-08-30Glob-import trans_build in other trans filesMarijn Haverbeke-53/+53
The capitalization already prevents name clashes. Being able to refer to the bitcode-construction primitives directly makes the code cleaner.