Paul Stansifer
a9cc5066ee
Change syntax extension syntax: #m[...]
-> m!{...}
.
2012-07-30 18:38:15 -07:00
Elliott Slaughter
c341eb9052
Don't emit invoke instructions inside landing pads.
...
We can't throw an exception from inside a landing pad without
corrupting the exception handler, so we have no hope of dealing with
these exceptions anyway. See:
http://llvm.org/docs/ExceptionHandling.html#cleanups
Part of #2861 .
2012-07-24 12:20:39 -07:00
Elliott Slaughter
d257382863
Moved malloc and free upcalls into rust runtime.
2012-07-23 10:45:58 -07:00
Niko Matsakis
0e42004bab
introduce an owned kind for data that contains no borrowed ptrs
2012-07-16 20:18:18 -07:00
Michael Sullivan
92743dc2a6
Move the world over to using the new style string literals and types. Closes #2907 .
2012-07-14 01:03:43 -07:00
Michael Sullivan
985b52be6d
Support prefix notation for vstore strings. Closes #2906 .
2012-07-13 17:03:49 -07:00
Michael Sullivan
e4362a59b9
Remove the empty tuple of tydescs from closures. Closes #2531 .
2012-07-10 15:12:13 -07:00
Michael Sullivan
95dd9f3204
Get rid of a lot of bind related cruft as part of Issue #2189 .
2012-07-10 15:12:12 -07:00
Michael Sullivan
25b152397d
Clean up the tydesc handling code in trans.
2012-07-10 15:12:12 -07:00
Patrick Walton
f093d374ed
rustc: Implement a new resolve pass behind a compile flag
2012-07-02 18:30:12 -07:00
Brian Anderson
d1fc2b5995
Convert to new closure syntax
2012-07-01 19:19:32 -07:00
Brian Anderson
a3382b6f26
Eliminate usages of old sugared call syntax
2012-06-30 16:01:49 -07:00
Michael Sullivan
98e161f00e
Switch the compiler over to using ~[] notation instead of []/~. Closes #2759 .
2012-06-29 17:41:45 -07:00
Eric Holk
59221e9ac8
replace more vector + (issue #2719 )
2012-06-28 13:52:23 -07:00
Patrick Walton
c1157161d9
rustc: Don't give variables the same name as enums in trans
...
Conflicts:
src/rustc/middle/trans/alt.rs
src/rustc/middle/trans/base.rs
src/rustc/middle/trans/closure.rs
src/rustc/middle/trans/impl.rs
src/rustc/middle/trans/uniq.rs
2012-06-27 14:11:02 -07:00
Eric Holk
b9d3ad0736
Getting rid of lots more vector +=. (issue #2719 )
2012-06-26 00:39:18 -07:00
Michael Sullivan
15b60ac56b
Comments only: fix some comments that got spurious /~s
2012-06-25 20:35:32 -07:00
Michael Sullivan
329eca6044
Make vectors uglier ([]/~). Sorry. Should be temporary. Closes #2725 .
2012-06-25 20:00:46 -07:00
Michael Sullivan
393f739990
Rename upcall_malloc_dyn to just upcall_malloc.
2012-06-21 10:47:45 -07:00
Brian Anderson
4dcf84e4f4
Remove bind. Issue #2189
2012-06-20 17:27:28 -07:00
Michael Sullivan
591b2802ff
Make trans only generate calls to the _dyn malloc upcalls, so we can get rid of the non dyn ones.
2012-06-13 18:00:17 -07:00
Brian Anderson
ce750a7dbc
Box AST idents
2012-06-13 11:30:45 -07:00
Tim Chevalier
88f03743b0
Comments only: annotate FIXMEs
2012-06-07 15:13:35 -07:00
Michael Sullivan
d542e67827
Do some cleanup of the allocation code.
2012-06-06 18:26:47 -07:00
Niko Matsakis
01b5777c8b
prohibit type parameters in native fns and other minor fixes
...
trans now can safely assert that it never sees a type param
2012-06-03 20:03:08 -07:00
Brian Anderson
80dc2e11a1
rustc: Remove the last use of upcall_shared_malloc
2012-05-30 21:23:34 -07:00
Brian Anderson
c6a23cddfb
rustc: Make unique closures use the new unique allocator
2012-05-30 21:23:34 -07:00
Brian Anderson
6d37c90ce6
rustc: Remove tuplify_cbox_ty. Unused
2012-05-30 21:23:33 -07:00
Niko Matsakis
1f4b3cfc36
zero out alloca for preserving values
...
conservatively do it always for now
2012-05-30 11:26:15 -07:00
Niko Matsakis
9e6a068034
replace last_use with liveness info
2012-05-25 14:37:30 -07:00
Brian Anderson
9aa18c2852
rustc: Move ast_map to the syntax crate
2012-05-21 23:39:27 -07:00
Niko Matsakis
5be8bf1de7
use -Z to distinguish internal debugging options
2012-05-18 10:38:18 -07:00
Tim Chevalier
8affc78e8a
Turn constants in back::abi into uints, and propagate types
...
This means GEPi now takes a list of uints. Apologies in advance
if this is hard to rebase against, but it gets rid of many a cast :-)
Also modernized some for loops here and there.
2012-05-03 22:31:38 -07:00
Tim Chevalier
9d274ec5f2
Re-rename option functions
...
get_with_default (nee from_maybe) => get_default
with_option (nee maybe) => map_default
with_option_do (nee may) => iter
As per discussion of 21be1379d5
2012-04-06 12:20:13 -07:00
Tim Chevalier
21be1379d5
Rename some core::option functions
...
from_maybe => get_with_default
maybe => with_option
may => with_option_do
I know these names are kind of ridiculous, but it's the best I could think of.
Feel free to bikeshed. Closes #2081
2012-04-02 16:12:49 -07:00
Marijn Haverbeke
b5a4fa9456
Move some code over to iterator-for to see how it performs.
2012-03-27 15:46:33 +02:00
Marijn Haverbeke
064f82d68d
Support returning from loop blocks
...
The code is somewhat invasive, but it seems hard to do this in a
clean way, since the design itself involves a bunch of 'action
at a distance'.
Issue #1819
2012-03-27 12:33:13 +02:00
Marijn Haverbeke
f6e3738b9c
Support an alternate for syntax that calls a higher-order function
...
The last argument of the call must be a block, and the type of this
argument must a function returning bool. `break` and `cont` are
supported in the body of the block, and return `false` or `true` from
the function. When the end of the function is reached, `true` is
implicitly returned.
for vec::all([1, 2, 3]) {|elt|
if elt == 2 { break; }
log(error, elt);
}
Issue #1619
2012-03-27 09:27:31 +02:00
Tim Chevalier
8bbd78075f
Handle self correctly when translating classes
...
This change uses the same code for handling the "self" reference for
classes as is already used for impls/ifaces. This allows removing the
extra maybe_self_id argument (which was just for classes) to trans_closure
that I added before. I also rewrote the translation for class ctors so
that it doesn't generate new AST nodes (instead translating directly).
Also changed visit so that it visits class ctors correctly with visit_fn,
and changed typestate to not do return-checking when visiting a class ctor.
2012-03-23 20:37:50 -07:00
Marijn Haverbeke
1b81c5112a
Remove last vestiges of old-style intrinsics
...
Closes #2048
2012-03-23 16:08:01 +01:00
Marijn Haverbeke
a84b56bc70
Remove more needless context threading in trans
2012-03-23 14:45:47 +01:00
Marijn Haverbeke
52d618a99a
Revert removal of intrinsics
...
Oops. We can't do this yet until the next snapshot.
2012-03-23 12:51:20 +01:00
Marijn Haverbeke
f5024692d4
Remove support for the old-style intrinsics
...
Closes #2042
Closes #1981
2012-03-23 12:21:55 +01:00
Marijn Haverbeke
ea2e379e4f
Implement built-in native modules as an alternative to intrinsics
...
Issue #1981
2012-03-23 10:49:47 +01:00
Graydon Hoare
b224bcf6e1
Add an LLVM-instruction-counting mode to trans.
...
Pipe to xdu to see a trans call graph of generated insns.
2012-03-22 13:44:20 -07:00
Niko Matsakis
b653a18416
add mut decls to rustc and make them mandatory
2012-03-21 21:04:14 -07:00
Graydon Hoare
56828d49fd
Remove unused "flav" parameter from function registration paths.
2012-03-20 15:16:12 -07:00
Marijn Haverbeke
22bef74b55
Remove shared tydescs
...
All tydescs are static now, there's no need to worry about
marshalling them between threads anymore.
2012-03-16 15:38:42 +01:00
Marijn Haverbeke
15a325f267
Support binding of methods off boxed iface values
...
Closes #435
2012-03-16 12:58:26 +01:00
Marijn Haverbeke
3ab9978b9b
Remove support for dynamically-sized types from translation code
2012-03-15 15:08:31 +01:00