Commit Graph

1495 Commits

Author SHA1 Message Date
Brian Anderson
5876da00cf Remove some erroneous FIXMEs from #fmt parser 2011-03-02 22:05:19 -05:00
Patrick Walton
7ab58db4d0 rustc: Use llsize_of rather than size_of in trans_malloc_without_cleanup(). Should put out burning tinderbox... 2011-03-02 18:36:03 -08:00
Patrick Walton
675f762621 rustc: Have make_generic_glue pass an opaque type instead of an incorrect type in the case of dynamically sized types 2011-03-02 18:23:38 -08:00
Patrick Walton
792af12a3c rustc: Remove unused call to type_of() in trans_tup() 2011-03-02 18:06:53 -08:00
Patrick Walton
ec5c5a750d rustc: Rework the API for trans_malloc() to be generic-aware and so that clients don't need to call trans_malloc_inner() 2011-03-02 17:31:01 -08:00
Graydon Hoare
dddeba19d3 Sketch out some more pieces of vec-append. 2011-03-02 16:42:19 -08:00
Patrick Walton
5ebb91f24d rustc: Teach iter_structural_ty about dynamically-sized tuples and records 2011-03-02 16:31:20 -08:00
Patrick Walton
21e42ad88a rustc: For derived tydescs, explicitly store 0 for size and align when the type in question has a dynamic size 2011-03-02 16:23:14 -08:00
Patrick Walton
c19e4e1c29 rustc: Don't have type_of_arg() rely on the particular lie told by type_of() 2011-03-02 16:15:20 -08:00
Graydon Hoare
fc722b17c9 Comment-out some logging chatter in extfmt. 2011-03-02 13:53:08 -08:00
Graydon Hoare
9e4943c922 Parse, add to AST, and otherwise ignore 'export' view items. Need to add support to resolve. 2011-03-02 13:50:42 -08:00
Graydon Hoare
d33110ebfc Comment-out TRACK_ALLOCATIONS again. Leave a note about it. 2011-03-02 13:43:33 -08:00
Brian Anderson
012c2d18d0 Finish #fmt string parsing. Completely untested. 2011-03-02 10:28:15 -08:00
Brian Anderson
4bc9052e13 Add debug logging for #fmt conv. Implement peek_num fn 2011-03-02 10:28:15 -08:00
Brian Anderson
77a0dc06a7 Whitespace cleanup 2011-03-02 10:28:15 -08:00
Brian Anderson
dbd90996ee Remove unused is_ext_expr 2011-03-02 10:28:15 -08:00
Brian Anderson
c1e6f5328c Make the expanded expression in expr_ext not optional 2011-03-02 10:28:15 -08:00
Brian Anderson
7cef1b3a0f Add pretty printing for expr_call, expr_path, and more literals 2011-03-02 10:28:14 -08:00
Brian Anderson
7350b7ff23 Add more #fmt tests 2011-03-02 10:28:14 -08:00
Brian Anderson
41a043303a Remove debug logging from extfmt 2011-03-02 10:28:14 -08:00
Brian Anderson
61edf544a2 Implement #fmt conversion for int and uint 2011-03-02 10:28:14 -08:00
Brian Anderson
f9144d5972 Start generating AST nodes for #fmt 2011-03-02 10:28:14 -08:00
Brian Anderson
1badf9316a Begin an AST pretty-printer 2011-03-02 10:28:14 -08:00
Brian Anderson
5e06ec977f Rewrite expand_syntax_ext to avoid a mysterious memory leak 2011-03-02 10:28:14 -08:00
Brian Anderson
fe5de6bfff Parse parameter types for fmt extension 2011-03-02 10:28:14 -08:00
Brian Anderson
f1500e5872 Add fold, typecheck and trans for expr_ext 2011-03-02 10:28:14 -08:00
Brian Anderson
1c60399257 Begin work on #fmt parsing 2011-03-02 10:28:14 -08:00
Brian Anderson
9528c34774 Begin implementing #fmt in rustc 2011-03-02 10:28:14 -08:00
Brian Anderson
e2d36e00ce Remove parens from nullary tag constructors in docs 2011-03-01 23:11:52 -05:00
Brian Anderson
727970c230 Remove reference to deceased rustboot LLVM backend 2011-03-01 23:11:52 -05:00
Graydon Hoare
64ab5eaaf0 Parse (and ignore) dtors on objs. 2011-03-01 17:33:17 -08:00
Patrick Walton
9869aebf7d rustc: Remove the static "size" field from the tag info 2011-03-01 16:58:33 -08:00
Graydon Hoare
7cae0c8c4d Implement the gross rustboot hack for contextual parser access to the compilation environment. 2011-03-01 16:50:32 -08:00
Patrick Walton
9d59d33515 rustc: Add in the size of the discriminant to generic_size_of() for tags 2011-03-01 16:49:05 -08:00
Patrick Walton
71f853b3fd rustc: Add logic for generic tags to dynamic_size_of(). 2011-03-01 16:37:17 -08:00
Patrick Walton
bdbaf0c789 rustc: Factor out the align-elements logic in dynamic_size_of() 2011-03-01 16:02:19 -08:00
Graydon Hoare
348c77c31b Populate default compilation environment as in rustboot. 2011-03-01 15:57:55 -08:00
Graydon Hoare
0761c5f462 Fix typo in comment. 2011-03-01 15:13:50 -08:00
Graydon Hoare
7f2398e557 Implement structured compare for rec, tup, tag. Un-XFAIL structured-compare.rs. 2011-03-01 13:00:58 -08:00
Patrick Walton
f239ecb5f2 rustc: Switch from storing nullary tags as constants to storing their discriminants 2011-03-01 12:41:41 -08:00
Patrick Walton
8d8b3d985a rustc: Mark tags that have subtypes with dynamic size as dynamic 2011-02-28 19:07:26 -08:00
Patrick Walton
687d328d7c rustc: Trivial cleanup: Remove unused "arity" tag 2011-02-28 18:27:50 -08:00
Graydon Hoare
d08f3a1c70 More complete sketch of structural compare. Still not quite working. 2011-02-28 17:49:26 -08:00
Graydon Hoare
1291cc2df9 Groundwork for structural comparison. Still lacking the actual loop that does it. 2011-02-28 16:36:14 -08:00
Patrick Walton
86309ed3ea rustc: Write tag variant discriminants into the crate as integer constants 2011-02-28 16:09:22 -08:00
Rafael Ávila de Espíndola
a172f5aef5 Declare wrappers to the native functions and use those to create
the fn/closure pairs.

Disable native2.rs for now as we are not yet defining the wrappers and it
fails to link.
2011-02-28 17:33:46 -05:00
Rafael Ávila de Espíndola
4ac4d03f0c Update the function declarations with rust abi. A cdecl
fn write(int fd, rustrt.vbuf buf, uint count) -> int;

compiles to

declare i32 @write(i32, i8*, i32)

and a rust

fn vec_buf[T](vec[T] v, uint offset) -> vbuf;

compiles to

declare i8* @vec_buf(%task*, %tydesc*, %"vec[<P0:2>]", i32)

which I think is the correct declaration for both :-)
2011-02-28 10:37:49 -05:00
Patrick Walton
0120571e90 rustc: Make the tag info table keyed by both tag ID and type parameter. Also fix a bug that was causing all tags to compare equal. 2011-02-25 19:42:26 -08:00
Patrick Walton
e37db13b02 rustc: Eliminate the "ty_params" field from the tag info 2011-02-25 18:24:58 -08:00
Patrick Walton
699eb69cc8 rustc: Eliminate the "variants" field from the tag info 2011-02-25 18:16:50 -08:00