about summary refs log tree commit diff
path: root/src/comp/middle
AgeCommit message (Collapse)AuthorLines
2011-06-15Reformat source tree (minus a couple tests that are still grumpy).Graydon Hoare-7523/+5582
2011-06-15rustc: Make room in remaining AST item nodes for attributesBrian Anderson-103/+105
Issue #487
2011-06-15rustc: Make room in item_mod for metadataBrian Anderson-17/+17
Issue #487
2011-06-15Implement checking against assignments to immutable obj fieldsMarijn Haverbeke-34/+59
2011-06-15Extend alias analysis to check assignmentsMarijn Haverbeke-2/+23
This is a somewhat odd place to put these checks, but the data tracked by that pass, and the available functions, make it trivial to do such a check there.
2011-06-15Fix assignments to immutable fields throughout the codeMarijn Haverbeke-25/+25
2011-06-15Refactor expr_root in alias.rsMarijn Haverbeke-73/+71
It was too clunky and specific before. Now returns a vec of dereference specs instead of a bunch of special-case information. Further accessors extract the information they need from this vec.
2011-06-14Merge pull request #490 from msullivan/fix_vec_appendPatrick Walton-45/+10
Move the implementation of vec_append from llvm assembly to a regular upcall
2011-06-14rustc: Implement on-heap resizing for interior vectorsPatrick Walton-24/+12
2011-06-14Make tydesc glue functions use cdecl.Michael Sullivan-7/+7
2011-06-14Remove vec_append_glue from the compiler.Michael Sullivan-37/+2
2011-06-14rustc: Free heapified interior vectorsPatrick Walton-0/+30
2011-06-14rustc: Fix LLVM type error that occurred when translating large unique ↵Patrick Walton-1/+1
vector literals
2011-06-14Implement upcall_vec_append and use it for vector append.Michael Sullivan-1/+1
2011-06-14Make the typechecker check that dynamically sized arguments are passed by aliasTim Chevalier-1/+11
Before, this would cause an assertion failure in trans.
2011-06-14Improve error message for a failed assert or checkTim Chevalier-4/+4
2011-06-14rustc: Do a dynamic alloca for generic interior vectors; fix data pointer ↵Patrick Walton-13/+16
calculation when spilling vectors
2011-06-14Don't error when trans_lval is called on a non-lvalMarijn Haverbeke-3/+5
This allows directly calling a function expression, or the result of an alt/if/block expression.
2011-06-14Implement function expressions/anonymous functionsMarijn Haverbeke-23/+74
Looks like 'fn(..arg..) -> ret {body;}. They don't support type parameters or upvars yet.
2011-06-13rustc: Implement simple interior vector append translationPatrick Walton-33/+251
2011-06-13Refactor some typestate-related data structuresTim Chevalier-143/+142
2011-06-13This is the mega-ucontext commit. It replaces the task switching mechanism ↵Eric Holk-7/+4
with a new one inspired by ucontext. It works under Linux, OS X and Windows, and is Valgrind clean on Linux and OS X (provided the runtime is built with gcc). This commit also moves yield and join to the standard library, as requested in #42. Join is currently a no-op though.
2011-06-13rustc: Assignment expressions have nil type. Closes #483Brian Anderson-13/+16
2011-06-13Change decl to local in expr_for and expr_for_eachTim Chevalier-198/+129
Since the decl in a for or for-each loop must always be a local decl, I changed the AST to express this. Fewer potential match failures and "the impossible happened" error messages = yay!
2011-06-12rustc: Preserve more type information for interior vectors at the LLVM ↵Patrick Walton-21/+38
level, allowing SROA to take place. `log ~[ 2 ].(0)` now optimizes to just `log 2`.
2011-06-11rustc: Use in-bounds GEPs for fetching length and data of interior vectorsPatrick Walton-6/+7
2011-06-11rustc: Translate interior vector index expressionsPatrick Walton-8/+57
2011-06-11rustc: Typecheck vector index expressions for interior vectorsPatrick Walton-12/+13
2011-06-10rustc: Sketch out translation of interior vector literals and take/drop gluePatrick Walton-23/+240
2011-06-10Reject programs with unsatisfied predicate constraintsTim Chevalier-178/+206
Generate appropriate constraints for calls to functions with preconditions, and reject calls where those constraints don't hold true in the prestate. ...by which I mean that it works for one test case :-)
2011-06-10More work on typechecking anon objs.Lindsey Kuper-11/+20
2011-06-10Oops, fix logging string specs. Nobody likes writing ↵Graydon Hoare-2/+1
RUST_LOG=_ZN5rustc5front7creaderE, do they?
2011-06-10Friendlier error message for break outside a loopTim Chevalier-7/+12
The typechecker should really check for this, but at least now there's an error message rather than an inexhaustive match failure in trans.
2011-06-10Use RHS type when translating assignmentsTim Chevalier-0/+6
In code like "auto foo = fail", a type gets inferred for foo depending on how it's used. However, fail still has type _|_ and still should be treated that way: particularly, its value shouldn't be copied. Fixed trans to reflect that.
2011-06-10rustc: Add a generic struct_elt() function to transPatrick Walton-4/+10
2011-06-10rustc: Derive flags for unsafe pointers. Puts out burning tinderbox.Patrick Walton-0/+4
2011-06-10Encode meta tags in the crate and start sketching enhanced logic for ↵Graydon Hoare-0/+36
resolving crate "use" directives. Now with extra "works on OSX" kludging.
2011-06-10rustc: Add some missing cases to ty.rs for interior vectors, and modify the ↵Patrick Walton-1/+46
pattern match so this is less likely to happen again. Add the LLVM type mapping as well.
2011-06-10rustc: Add missing cases for istr and ivec to equal_type_structures()Patrick Walton-0/+12
2011-06-10Merge pull request #447 from paulstansifer/quick_error_message_fixPatrick Walton-2/+17
Error message, instead of segfault, when recursive types are used.
2011-06-10rustc: Remove the bitwise not operatorPatrick Walton-5/+10
2011-06-10Dead code elimination.Lindsey Kuper-27/+0
2011-06-10Minimal comment for visit.rsMarijn Haverbeke-1/+7
2011-06-10Move some uses of walk to visit in trans.rsMarijn Haverbeke-75/+46
2011-06-10Handle mutable references in alias analysisMarijn Haverbeke-32/+78
2011-06-10Fix unsafe uses of mutable referencesMarijn Haverbeke-23/+25
2011-06-10Implement mutable/immutable alias distinction.Marijn Haverbeke-42/+73
Before, all aliases were implicitly mutable, and writing &mutable was the same as writing &. Now, the two are distinguished, and assignments to regular aliases are no longer allowed.
2011-06-10Fix all occurrences of writing to immutable aliasesMarijn Haverbeke-12/+13
You'd be surprised.
2011-06-09Sketching trans_anon_obj.Lindsey Kuper-7/+219
2011-06-09Revert "Encode meta tags in the crate and start sketching enhanced logic for ↵Patrick Walton-36/+0
resolving crate "use" directives." due to tree bustage This reverts commit ab3635eebef2b8cf0e19cdbc5b4e8dd7a49a4658.