Brian Anderson
92a716d862
Remove usages of case(_) { fail; } since the compiler does this automatically
2011-03-22 08:11:34 -07:00
Brian Anderson
530fe1daea
Add a cleanup to trans_send. Express further confusion about cleanups in trans_recv
2011-03-22 08:04:53 -07:00
Brian Anderson
cddd8094da
Remove a todo from trans_chan that doesn't appear necessary
2011-03-22 08:04:49 -07:00
Brian Anderson
c02cdc32a8
Generalize send/recv to work for more types
2011-03-22 08:04:45 -07:00
Brian Anderson
39c01c97ba
Fix trans_recv
2011-03-22 08:04:41 -07:00
Brian Anderson
b2ee569c23
Implement trans_send and a broken trans_recv
2011-03-22 08:04:39 -07:00
Brian Anderson
261d1e4c61
Add codegen for ports and chans
2011-03-22 08:04:38 -07:00
Tim Chevalier
1e1ff638a3
Make floating-point operations work (neg, add, sub, mul, div, rem,
...
and comparison ops.)
2011-03-21 18:10:34 -07:00
Tim Chevalier
caa22c9341
Started adding support for floating-point type, floating-point literals, and logging of floats. Other operations on float probably don't work yet.
2011-03-21 18:10:34 -07:00
Rafael Ávila de Espíndola
933c01bd15
Every upcall needs a task pointer to find the C stack. It is just that when
...
handling cdecl call they should skip it when calling the final function.
There is some cleanup to be done on the generated IL, but this gets us
running Hello World for real.
2011-03-21 17:53:11 -04:00
Rafael Ávila de Espíndola
f3057244a6
Make the wrapper function of native functions private.
2011-03-21 16:02:00 -04:00
Rafael Ávila de Espíndola
12e7feb71c
The T_taskptr is already included in the n_args, don't add it twice.
2011-03-21 15:15:22 -04:00
Patrick Walton
84c0d8638e
rustc: Update type serialization and deserialization for the "mutable?" change
2011-03-21 11:44:08 -07:00
Marijn Haverbeke
86d05655b4
rustc: Merge in type serialization and deserialization
...
Signed-off-by: Patrick Walton <pcwalton@mimiga.net>
2011-03-21 11:35:04 -07:00
Rafael Ávila de Espíndola
e687dd5ce7
Make lltaskptr a regular argument element in args in calls to trans_upcall2.
2011-03-21 11:59:14 -04:00
Rafael Ávila de Espíndola
770a49520c
Move calls to PtrToInt out of trans_upcall2.
2011-03-21 11:11:22 -04:00
Graydon Hoare
4b946cea35
Modify native_item_fn to handle trailing linkage names that differ from the item name (used in win32 build of std.dll)
2011-03-20 20:18:19 -07:00
Patrick Walton
d31bfc8692
rustc: Internalize glue. Cuts libstd size by 8% or so.
2011-03-20 15:05:13 -07:00
Patrick Walton
277d42f589
rustc: Only declare each native function once. std.rc now links.
2011-03-19 17:33:46 -07:00
Patrick Walton
a1aad28690
rustc: Use the right block context to generate unary operands. std.rc compiles now. For realz.
2011-03-19 15:03:21 -07:00
Patrick Walton
8e597b295f
rustc: Allow arguments to be captured as upvars. std.rc compiles now, except for the lack of a main fn.
2011-03-19 14:26:12 -07:00
Patrick Walton
c710c9a1b8
rustc: Do argument casts before loading aggregates, not after
2011-03-19 13:58:48 -07:00
Patrick Walton
3f2bae4449
rustc: Implement int-to-native casts
2011-03-18 18:49:59 -07:00
Patrick Walton
e6b6d1b645
rustc: Make trans_path() generic-safe wrt nullary tags
2011-03-18 18:45:49 -07:00
Patrick Walton
95dc89f012
rustc: Make iter_structural_ty_full() generic-safe wrt tags
2011-03-18 18:34:06 -07:00
Patrick Walton
8c48fae726
rustc: Do pointer casts when casting native types
2011-03-18 18:12:58 -07:00
Patrick Walton
9c0c0af1b2
rustc: Fix inference for auto slots (forgot to stage changes before)
2011-03-18 17:45:47 -07:00
Patrick Walton
f3b58947c0
rustc: Don't always build a constant multiply instruction when translating literal vectors; the size of the referent isn't always constant
2011-03-18 16:41:56 -07:00
Patrick Walton
533dea772f
rustc: Move type_of() behind the check for dynamic size in trans_vec()
2011-03-18 16:34:22 -07:00
Patrick Walton
78bcfe28f2
rustc: Create global variable constants during the collection phase
2011-03-18 16:24:01 -07:00
Patrick Walton
8ff77b14a9
rustc: Make iter_sequence() work with generic vectors
2011-03-18 16:04:16 -07:00
Patrick Walton
47d650e25b
rustc: Box the tuples returned by hashmap.items() for now since we don't have alias iterators yet
2011-03-18 15:18:45 -07:00
Patrick Walton
ebee49314b
rustc: Get type params from the item when translating native items
2011-03-18 15:01:45 -07:00
Patrick Walton
e8938f5fb2
rustc: Unify over alt expressions
2011-03-18 12:49:48 -07:00
Patrick Walton
6f65ce5255
rustc: Add a span_unimpl() for debugging
2011-03-18 12:30:44 -07:00
Patrick Walton
2ef9c01ffc
rustc: Implement "mutable?". Add a test case and XFAIL it in rustboot for now.
2011-03-18 11:49:47 -07:00
Patrick Walton
5eca7129e3
rustc: Switch mutability from being a type constructor to a field annotation
2011-03-17 17:39:47 -07:00
Patrick Walton
67bac63aa3
rustc: Correctly report mutability when stringifying types
2011-03-17 11:54:00 -07:00
Patrick Walton
2ca66718ce
rustc: Consider native types to be scalar
2011-03-17 11:46:21 -07:00
Patrick Walton
55587a554c
rustc: Sort object methods when parsing textual types in the AST
2011-03-17 11:40:05 -07:00
Patrick Walton
bc51842d4f
rustc: Don't go over inner functions' locals during the writeback phase of typechecking
2011-03-17 11:23:17 -07:00
Rafael Ávila de Espíndola
9dc3f3f183
Fixed version of my previous patch to rename the upcall functions. This time also update the inline assembly.
2011-03-16 18:09:12 -04:00
Graydon Hoare
54587bdccb
Switch all vases of vec += elt to vec += vec. Prohibit former in rustboot. Tweak std lib vec fns in process.
2011-03-16 14:58:02 -07:00
Rafael Ávila de Espíndola
8dc5059058
Update comment to reflect the decision to avoid cycles.
2011-03-16 11:29:41 -04:00
Patrick Walton
71b6e602c5
rustc: Add an annotation for the crate definition to view_item_use
2011-03-15 17:33:05 -07:00
Patrick Walton
341d128ad3
Revert "Change the numbering of upcall functions. upcall_0 now calls a function" due to tinderbox failure on win32
...
This reverts commit bd9dd5ed1a
.
2011-03-15 17:20:00 -07:00
Rafael Ávila de Espíndola
bd9dd5ed1a
Change the numbering of upcall functions. upcall_0 now calls a function
...
with no arguments. This is still preparation for calling functions that
don't take a rust task argument.
2011-03-15 16:24:03 -04:00
Graydon Hoare
7f5bffc3ea
Merge remote branch 'brson/recursive-elseif'
2011-03-14 16:59:04 -07:00
Brian Anderson
8b5574ac09
Rename check_assignment_like to check_assignment since it turned out not to be useful for send/recv
2011-03-14 16:41:46 -07:00
Brian Anderson
b83a4af93c
Fix the typechecking for expr_send and expr_recv
2011-03-14 16:41:46 -07:00