Commit Graph

1671 Commits

Author SHA1 Message Date
bors
4e78c1e2a8 auto merge of #7479 : mozilla/rust/rollup, r=thestinger
22b7eb3 r=thestinger 
28a3613 r=cmr
a0c31ec r=bstrie
ee7307e r=thestinger
b9cf6a3 r=thestinger
2013-06-28 22:25:48 -07:00
Young-il Choi
21cc0ccea1 librustc: fix #7467 for android 2013-06-29 01:22:35 -04:00
Brian Anderson
22b7eb3802 Rename #[mutable] to #[no_freeze] 2013-06-29 00:56:36 -04:00
Brian Anderson
4af7ebcd8f Rename #[non_sendable] to #[no_send] 2013-06-29 00:56:36 -04:00
bors
d681bccb6a auto merge of #7471 : msullivan/rust/default-methods, r=graydon
This fixes a bunch of default method bugs and restructures how vtable resolutions are represented.

(It also adds a depth counter to llvm::type_to_str as a hacky work around for our circular llvm types. This is related in the sense that I needed to do it to make debug tracing not cause rustc to crash after running out of stack space.)
2013-06-28 20:16:56 -07:00
Michael Sullivan
c05165bf93 Drop the impl_id field from fn_ctxt. 2013-06-28 18:09:02 -07:00
Michael Sullivan
5943118728 Drop an unused field from param_substs. 2013-06-28 18:09:02 -07:00
Michael Sullivan
0252693db2 Improve handling of trait bounds on a trait in default methods.
This is work on #7460.
It does not properly handle certain cross crate situations,
because we don't properly export vtable resolution information.
2013-06-28 18:09:02 -07:00
bors
e23934645a auto merge of #7466 : thestinger/rust/passes, r=cmr 2013-06-28 16:49:49 -07:00
Michael Sullivan
649b26f7c6 Rework vtable_res to not be flattened. It is now a list of the resolutions for each param. 2013-06-28 16:12:08 -07:00
Michael Sullivan
57ee34c2bf Actually resolve trait bounds on impls. Closes #7266. 2013-06-28 16:12:08 -07:00
Michael Sullivan
817f98085f Make calling methods parameterized on the trait work from default methods.
This is done by adding a new notion of "vtable_self".
We do not yet properly handle super traits.

Closes #7183.
2013-06-28 16:12:08 -07:00
Michael Sullivan
a9e51f5f70 Make default method handling not choke on self region params. Closes #7341. 2013-06-28 16:12:08 -07:00
Michael Sullivan
050d0e6b29 Add a depth counter to llvm::type_to_str to work around infinite llvm types. 2013-06-28 16:12:04 -07:00
Michael Sullivan
47afb33981 Add Float to llvm::type_to_str. 2013-06-28 16:12:04 -07:00
Daniel Micay
2bdc88b652 copy the optimization passes from clang 2013-06-28 18:18:09 -04:00
James Miller
fae4a9e5ba Rename Const/Owned in more places 2013-06-28 10:47:59 -04:00
Patrick Walton
10bcb60e8f librustc: Fix even *MORE* merge fallout! 2013-06-28 10:47:59 -04:00
Patrick Walton
f25f466afe librustc: Fix even *more* merge fallout! 2013-06-28 10:47:59 -04:00
Patrick Walton
3625781cfe librustc: Fix more merge fallout. 2013-06-28 10:44:17 -04:00
Patrick Walton
bb830558d1 librustc: Fix merge fallout and test cases. 2013-06-28 10:44:17 -04:00
Patrick Walton
e015bee286 Rewrite each_path to allow performance improvements in the future.
Instead of determining paths from the path tag, we iterate through
modules' children recursively in the metadata. This will allow for
lazy external module resolution.
2013-06-28 10:44:16 -04:00
Patrick Walton
89eb995195 librustc: Fix merge fallout. 2013-06-28 10:44:16 -04:00
Patrick Walton
03ab6351cc librustc: Rewrite reachability and forbid duplicate methods in type implementations.
This should allow fewer symbols to be exported.
2013-06-28 10:44:16 -04:00
Patrick Walton
a1531ed946 librustc: Remove the broken overloaded assign-ops from the language.
They evaluated the receiver twice. They should be added back with
`AddAssign`, `SubAssign`, etc., traits.
2013-06-28 10:44:16 -04:00
Patrick Walton
f463e69d20 librustc: Add a small vector optimization for GEPi. Shaves a second off trans, I think? 2013-06-28 10:44:15 -04:00
Patrick Walton
f9b54541ee librustc: Disallow "mut" from distributing over bindings.
This is the backwards-incompatible part of per-binding-site "mut".
2013-06-28 10:44:15 -04:00
Patrick Walton
1c0aa78481 librustc: Change "Owned" to "Send" everywhere 2013-06-28 10:44:15 -04:00
Patrick Walton
1eec3bba13 librustc: Rename Const to Freeze 2013-06-28 10:44:15 -04:00
Patrick Walton
d350981c0e librustc: Change Const to Freeze in the compiler 2013-06-28 10:44:15 -04:00
Patrick Walton
607b91d5f9 librustc: Rename Owned to Send in the compiler 2013-06-28 10:44:07 -04:00
bors
811e045c60 auto merge of #7426 : thestinger/rust/zero-size-noncopyable, r=catamorphism
4885918 r=huonw
42a63fc r=thestinger
7ec5a08 r=catamorphism
fb1e5f1 r=thestinger
659cd55 r=cmr
2013-06-28 05:28:32 -07:00
bors
8600c18812 auto merge of #7272 : Aatch/rust/namegen_thunk, r=thestinger
This removes the `namegen` thunk that was in `common.rs`. I also take the opportunity to refactor a few uses where we had a `str -> ident -> str` chain that seemed somewhat redundant to me.

Also cleans up some warnings that made their way in already.
2013-06-28 01:01:52 -07:00
James Miller
a897a9ab9f Remove useless namegen thunk 2013-06-28 18:00:20 +12:00
Birunthan Mohanathas
dcf1dc060a Rename #[no_drop_flag] to #[unsafe_no_drop_flag] 2013-06-27 23:20:42 -04:00
bors
61dc7760d0 auto merge of #7410 : luqmana/rust/bare-self, r=catamorphism
Finally sorted this out. Fixes #5321, #4439, and #4850.
2013-06-27 20:19:38 -07:00
Luqman Aden
767374976b librustc: Always pass self ByRef. 2013-06-27 21:36:30 -04:00
bors
927f454ac1 auto merge of #7432 : michaelwoerister/rust/WP3, r=jdm 2013-06-27 17:22:42 -07:00
bors
63afb8ccc8 auto merge of #7430 : huonw/rust/vec-kill, r=thestinger 2013-06-27 15:01:58 -07:00
Michael Woerister
2f5e33d02f debuginfo: Some corrections after review. 2013-06-27 19:28:37 +02:00
Michael Woerister
6af78610e7 debuginfo: Added support for region pointers. 2013-06-27 19:28:37 +02:00
Michael Woerister
46d28c874c debuginfo: Replaced many instances of @ with &. 2013-06-27 19:28:17 +02:00
Michael Woerister
4d8f2fd871 debuginfo: Many little formatting improvements. 2013-06-27 19:28:17 +02:00
Michael Woerister
7bb189e56c Fixed debug information bug regarding struct padding. 2013-06-27 19:28:17 +02:00
bors
36527360a6 auto merge of #7429 : Blei/rust/delete-shared, r=huonw
Mostly just low-haning fruit, i.e. function arguments that were @ even
though & would work just as well.

Reduces librustc.so size by 200k when compiling without -O, by 100k when
compiling with -O.
2013-06-27 08:28:37 -07:00
Huon Wilson
29b0649a6a Convert vec::{push, push_all, push_all_move} to methods. 2013-06-28 00:20:42 +10:00
Huon Wilson
1cb0a567d1 Convert vec::{pop, shift, unshift, insert, remove, swap_remove} to methods. 2013-06-28 00:20:42 +10:00
Philipp Brüschweiler
7295a6da92 Remove many shared pointers
Mostly just low-haning fruit, i.e. function arguments that were @ even
though & would work just as well.

Reduces librustc.so size by 200k when compiling without -O, by 100k when
compiling with -O.
2013-06-27 15:06:19 +02:00
bors
c440743dcc auto merge of #7403 : catamorphism/rust/package-scripts, r=brson
r? @brson (or @graydon if available) rustpkg/api.rs provides functions intended for package scripts to call.
It will probably need more functionality added to it later, but this is
a start.

Added a test case checking that a package script can use the API.

Closes #6401
2013-06-27 06:01:30 -07:00
Huon Wilson
d2e3e1e52b Convert vec::{head, tail, init, last} (and similar fns) to methods. 2013-06-27 22:37:00 +10:00