Graydon Hoare
3aac5059ee
Move the glue code to a .o file. This reduces how much asm we print
...
in each "translation unit".
Part of it is not repetitive and should probably be moved to a .ll file, but
for now we autogen all of it.
(Modified somewhat by graydon while integrating).
2011-03-10 17:30:08 -08:00
Patrick Walton
7454b53411
rustc: Build up a list of upvars inside foreach bodies
2011-03-10 16:49:00 -08:00
Patrick Walton
60f86354ad
rustc: Use the generic info from the item in bind thunks just as calls do. Un-XFAIL drop-parametric-closure-with-bound-box.rs.
2011-03-10 15:14:45 -08:00
Patrick Walton
185bcc6218
rustc: Increment the counter in trans_bind_thunk()
2011-03-10 15:09:41 -08:00
Patrick Walton
41d5094a8e
rustc: Fix off-by-one error and logic error regarding type parameters in the translation of bind expressions. Un-XFAIL bind-obj-ctor.rs.
2011-03-10 14:38:06 -08:00
Patrick Walton
36b81abf61
rustc: Perform a cast in vector initialization due to changing layers of indirection. Keep test/run-pass/size-and-align.rs XFAIL'd due to a leak in rustboot.
2011-03-10 12:15:07 -08:00
Patrick Walton
7505c1fa23
rustc: Run cleanups on while expressions' condition blocks. Un-XFAIL while-prelude-drop.rs.
2011-03-10 11:46:37 -08:00
Graydon Hoare
8e8c336f93
Implement deep structural comparison through boxes and sequences.
2011-03-09 20:14:19 -08:00
Patrick Walton
874e8e3505
rustc: Have tag patterns use the type parameter information from the typechecker instead of trying to deduce it in trans. Un-XFAIL test/run-pass/generic-tag-values.rs.
2011-03-09 17:50:46 -08:00
Patrick Walton
ea2c868744
rustc: Perform type substitutions for tag variants in dynamic_size_of()
2011-03-09 16:07:55 -08:00
Patrick Walton
1e65baad94
rustc Remove dead "llunit_ty" assignment in trans_index
2011-03-09 15:23:41 -08:00
Patrick Walton
7dc64b45b5
rustc: Make tag pattern translation generic-aware. Un-XFAIL generic-tag-alt.rs.
2011-03-09 15:17:06 -08:00
Patrick Walton
ba2e04f271
Rename confusing usage of "lltag" to "lldiscrim" in trans_pat_match()
2011-03-09 14:29:00 -08:00
Patrick Walton
2986ed43e9
rustc: Substitute type parameters in type_of_variant(). Add a test case.
2011-03-09 13:31:25 -08:00
Patrick Walton
9aa26904b8
rustc: Remove redundant ty_params_of_tag() function
2011-03-09 13:07:06 -08:00
Patrick Walton
80fa01fb57
rustc: Perform type parameter substitutions in static_size_of_tag()
2011-03-09 12:53:12 -08:00
Patrick Walton
fcd195bb4c
rustc: Don't try to load dynamically-sized types when translating tag variants. Add a test case for this.
2011-03-09 12:53:12 -08:00
Rafael Ávila de Espíndola
02f669ca67
Pass the task pointer as just another i32.
2011-03-09 15:35:54 -05:00
Rafael Ávila de Espíndola
aeca138944
swap taskptr and callee in preparation for making taskptr optional.
2011-03-09 14:16:11 -05:00
Patrick Walton
e62424944b
rustc: Have trans get the type parameters from the annotation instead of trying to deduce them itself. Un-XFAIL generic-fn-twice.rs.
2011-03-08 16:56:19 -08:00
Graydon Hoare
01bfc3ae8b
Fix generic-bind support for bound aliases and generics.
2011-03-08 16:32:39 -08:00
Patrick Walton
da9ea9ab69
rustc: Move type parameter resolution from translation into the typechecker
2011-03-08 14:55:39 -08:00
Graydon Hoare
27547c6514
Revert "Move the glue asm code to a .o file. This reduces how much asm we print"
...
This reverts commit 55c80e763bfd850682b3217fcfc5cdb516eafae0.
2011-03-08 13:20:16 -08:00
Rafael Ávila de Espíndola
55c80e763b
Move the glue asm code to a .o file. This reduces how much asm we print
...
in each "translation unit".
2011-03-08 13:08:31 -08:00
Patrick Walton
4654faa67c
rustc: Add a slot for explicit type parameter instantations to the typechecker's AST annotation
2011-03-08 12:42:56 -08:00
Brian Anderson
9fc4db6b89
Merge branch 'master' into recursive-elseif
...
Conflicts:
src/Makefile
src/comp/front/ast.rs
src/comp/front/parser.rs
src/comp/middle/fold.rs
src/comp/middle/trans.rs
2011-03-07 21:21:01 -05:00
Graydon Hoare
0d60918855
Most of the way through genericizing bind properly with new malloc path. Still getting the thunk call wrong.
2011-03-07 18:13:56 -08:00
Patrick Walton
3473ff3bff
rustc: Cast dynamically-sized tags in iter_structural_ty_full() to opaque tag types. Un-XFAIL generic-recursive-tag.rs.
2011-03-07 18:03:33 -08:00
Patrick Walton
6ed226c6b3
rustc: Cast the LLVM representations of tag types when constructing boxes. Un-XFAIL list.rs.
2011-03-07 16:35:00 -08:00
Patrick Walton
6f7e21ddac
rustc: Truncate or zero-extend indexes appropriately. Un-XFAIL integral-indexing.rs.
2011-03-07 15:44:42 -08:00
Graydon Hoare
abbcc0385d
Poison ty_param values in trans; fix buggy parametric obj and box malloc paths. Add generic-box test.
2011-03-07 14:05:16 -08:00
Rafael Ávila de Espíndola
8047957b99
Construct the wrappers to native functions. Hello world now works :-)
2011-03-07 15:37:40 -05:00
Graydon Hoare
60657fa8aa
Set the cleanup on the post-growth vector, not the temporary one.
2011-03-07 00:13:56 -08:00
Graydon Hoare
2cbfb8795d
Fix off-by-one in vector append code.
2011-03-06 23:06:01 -08:00
Graydon Hoare
386ba3ae63
Further work on vec-append. Almost working.
2011-03-06 22:37:14 -08:00
Brian Anderson
d39da6f978
Remove typestate workarounds
2011-03-06 15:13:35 -08:00
Graydon Hoare
138c55a69d
Fix return value on trans_vec_add.
2011-03-06 15:12:33 -08:00
Graydon Hoare
3eb20f3f6e
Correct signatures and arguments associated with call into vec_append_glue.
2011-03-06 12:46:33 -08:00
Patrick Walton
94b681afe4
rustc: Use copy_ty() when initializing N-ary tag variants. Un-XFAIL generic-tag.rs.
2011-03-04 18:05:48 -08:00
Patrick Walton
1dc6bdf331
rustc: Don't recurse forever if type glue needs to refer to its own type descriptor
2011-03-04 17:22:43 -08:00
Patrick Walton
0aa74828e3
rustc: Remove "translating variants" debug string
2011-03-04 15:15:12 -08:00
Patrick Walton
76ec67063e
rustc: Don't use recursive types for tags; remove tag_info; introduce GEP_tag()
2011-03-04 15:10:22 -08:00
Rafael Ávila de Espíndola
95c0cefd32
Build empty wrappers. This lets us compile hello world, but so far it
...
just returns 0.
2011-03-04 15:29:33 -05:00
Rafael Ávila de Espíndola
2ff67ed94e
Remove unused argument.
2011-03-04 14:53:52 -05:00
Graydon Hoare
652cb48475
Assortment of additional work on vec-append. Not done yet.
2011-03-03 18:18:59 -08:00
Patrick Walton
629eba1d06
rustc: Make tag discriminants per-tag-ID, not per-tag-ID-and-subtypes
2011-03-03 18:15:17 -08:00
Graydon Hoare
b4a85c7b58
Factor out and generalize sequence pointer walking, for use in vec-grow.
2011-03-03 17:36:38 -08:00
Patrick Walton
04a0a6fbef
Revert "rustc: Add support for folding over tag types" as it's unnecessary. Oops.
2011-03-03 17:09:20 -08:00
Patrick Walton
f6682280f3
rustc: Add support for folding over tag types
2011-03-03 16:54:15 -08:00
Patrick Walton
39b0563205
rustc: Remove dead code that used to generate tag constants from trans_constant()
2011-03-03 16:18:43 -08:00