about summary refs log tree commit diff
path: root/src/comp/middle
AgeCommit message (Collapse)AuthorLines
2011-07-22Start adding support for multiple variable declarations per stmtMarijn Haverbeke-25/+47
This adds parser support and most of the machinery for auto x = 10, y = 20; However, the above still goes wrong somewhere in typestate, causing the state checker to believe only the last variable in the list is initialized after the statement. Tim, if you have a moment, could you go over the changes to the tstate code in this patch and see where I'm going wrong? Multi-var-decls without the typestate extension Add a loop
2011-07-22Rewrite trans_cast, float->float and float->int castsMarijn Haverbeke-50/+63
2011-07-22Report unresolved names only once per functionMarijn Haverbeke-32/+52
Closes #708
2011-07-22Fix unboxing in alias passMarijn Haverbeke-15/+27
The alias checker would only deref once for autoderef, and only deref boxes. It should now do the right thing. Closes #725.
2011-07-21Removing unnecessary argument from process_fwding_mthd().Lindsey Kuper-6/+1
2011-07-21Clean up build_environment by having it return a rec with usefully named fields.Michael Sullivan-7/+5
2011-07-21Add some useful functions to freevars.Michael Sullivan-2/+25
2011-07-21Add some support for using a map like a set.Michael Sullivan-0/+5
2011-07-21Move a bunch of trans into trans_common, including the context structures.Michael Sullivan-385/+367
Probably more should be moved or split off into other files. My algorithm was something along the lines of: move the contexts and their transitive dependencies along with some functions to work with them. I stopped when I was going to have to start pulling glue generation, which really should go into a trans_glue file.
2011-07-21Make ty::ctxt be boxed.Michael Sullivan-49/+44
Arguably we should leave ty_ctxt as a bare rec and just always work with boxes of it. This winds up being simpler and prettier, though.
2011-07-21Instantiate function preconditions inside the function bodyTim Chevalier-6/+53
so that if we have a function like: f(...) : p(x) { ... } p(x) is true inside the body of f. Closes #694.
2011-07-21Move ast_constr_to_constr from typeck to tyTim Chevalier-22/+24
so that it can be used in places that import ty.
2011-07-21Now with more type inference.Lindsey Kuper-43/+42
2011-07-21Comments and cleanup.Lindsey Kuper-4/+3
2011-07-21Consolidate obj_field_from_anon_obj_field().Lindsey Kuper-10/+3
2011-07-21Remove vestiges of typarams from anon objs.Lindsey Kuper-65/+27
2011-07-21Improving move semantics for channel operations.Eric Holk-4/+5
This lets us un-XFAIL task-comm-10.rs.
2011-07-21Lots of work on memory tracking and channels.Eric Holk-55/+55
We're trying to get closer to doing correct move semantics for channel operations. This involves a lot of cleanup (such as removing the unused sched parameter from rust_vec constructor) and making circular_buffer kernel_owned. Added tagging for memory allocations. This means we give a string tag to everything we allocate. If we leak something and TRACK_ALLOCATIONS is enabled, then it's much easier now to tell exactly what is leaking.
2011-07-21Revert "rustc: Avoid SHA-1 hashing every type, since they're interned"Patrick Walton-4/+4
This reverts commit df90f57a5f76059394abd8328d30003b844cb497.
2011-07-21rustc: Box raw types. Shaves about 5 seconds off compilation.Patrick Walton-17/+17
2011-07-21rustc: Avoid SHA-1 hashing every type, since they're internedPatrick Walton-4/+4
2011-07-20rustc: Remove cnames for nowPatrick Walton-1/+2
2011-07-20rustc: Strip cnames before generating glue to avoid duplicatesPatrick Walton-2/+11
2011-07-20rustc: Translate functions only oncePatrick Walton-0/+1
2011-07-20Box the vec of freevars we store in the freevars cache.Michael Sullivan-6/+6
2011-07-20Refactoring and cleaning up.Lindsey Kuper-16/+11
2011-07-20Fix typo.Rafael Ávila de Espíndola-1/+1
2011-07-20give rust_metadata internal linkage but mark it as used. This allowsRafael Ávila de Espíndola-0/+11
multiple static crates to be used.
2011-07-19Add missing case in tyencode for ty_constrTim Chevalier-0/+1
Fixes the Windoze breakage, I hope.
2011-07-19Typechecking self-calls in anon objs. Closes #540.Lindsey Kuper-30/+50
2011-07-19Clean up formatting.Lindsey Kuper-13/+10
2011-07-19Beginnings of support for constrained typesTim Chevalier-237/+368
Programs with constrained types now parse and typecheck, but typestate doesn't check them specially, so the one relevant test case so far is XFAILed. Also rewrote all of the constraint-related data structures in the process (again), for some reason. I got rid of a superfluous data structure in the context that was mapping front-end constraints to resolved constraints, instead handling constraints in the same way in which everything else gets resolved.
2011-07-19Style and indentation cleanups.Lindsey Kuper-19/+19
2011-07-19Some progress on issue #540.Lindsey Kuper-44/+76
2011-07-19Comments and cleanup.Lindsey Kuper-9/+7
2011-07-19Wrapping long strings.Lindsey Kuper-7/+7
2011-07-19Add a pass that finds all of the free variables.Michael Sullivan-16/+62
2011-07-19Move collect_upvars into its own file.Michael Sullivan-72/+95
2011-07-19rustc: Report how much time was spent to translate each function when ↵Patrick Walton-14/+60
--stats is on
2011-07-19Fix trans_alt to handle unreachable branches without blowing upMarijn Haverbeke-12/+25
2011-07-18rustc: Translate locals in DPS stylePatrick Walton-1/+22
2011-07-18rustc: Remove obsolete TODOPatrick Walton-1/+0
2011-07-18rustc: Skip null when translating string concatenationPatrick Walton-1/+6
2011-07-18rustc: First stab at implementing interior vector concat in the DPS enginePatrick Walton-27/+266
2011-07-18Don't use 'obj_info' as an identifier for things not of type obj_info.Lindsey Kuper-5/+5
2011-07-18Sane error message for self-call in non-obj context. Closes #707.Lindsey Kuper-2/+7
2011-07-18Support x86 stdcall conventionBrian Anderson-6/+26
This allows rust to call the Win32 API
2011-07-18rustc: Stub binary operator translationPatrick Walton-0/+47
2011-07-17rustc: Simplify the destination format in the DPS backend; optimize aliases ↵Patrick Walton-90/+103
to interior strings to require no allocation at all
2011-07-17rustc: Use memmove instructions more aggressively in DPS mode. LLVM converts ↵Patrick Walton-13/+74
these to optimized block transfer instructions, significantly reducing code size.