Ben Blum
ff4ab9e147
'Borrow' stack closures rather than copying them (e.g., "|x|f(x)"), in prep for making them noncopyable.
2013-06-29 04:39:34 -04:00
Ben Blum
5784c0912f
Change taskgroup key type to fn:Copy in prep for noncopyable stack closures.
2013-06-29 03:58:50 -04:00
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
blake2-ppc
b9cf6a33d2
iterator: UnfoldrIterator::new should have function argument last
...
To match Rust conventions and enable use of `do` etc, make sure the
closure is the last argument to the `new` method.
2013-06-29 01:03:37 -04:00
Brian Anderson
22b7eb3802
Rename #[mutable] to #[no_freeze]
2013-06-29 00:56:36 -04:00
Michael Sullivan
a9e51f5f70
Make default method handling not choke on self region params. Closes #7341 .
2013-06-28 16:12:08 -07:00
Corey Richardson
d600601162
Add each_parent to WindowsPath
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
f6a27cbda2
libextra: Fix even more merge fallout.
2013-06-28 10:47:56 -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
8cd40f9032
libstd: Fix merge fallout.
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
887ae82382
auto merge of #7397 : catamorphism/rust/rustpkg_path, r=catamorphism
...
r? @brson Unfortunately, the main test for this is ignored due to #7071 .
Closes #5682
2013-06-28 02:58:34 -07:00
Tim Chevalier
ea62fd1090
rustpkg: Implement RUST_PATH
...
Unfortunately, the main test for this is ignored due to #7071 .
Closes #5682
2013-06-27 21:41:03 -07:00
Daniel Micay
c45af01351
fix stage0 build
2013-06-28 00:23:38 -04:00
Young-il Choi
6b2297d118
std: unused import fix for android
2013-06-27 23:21:40 -04:00
Birunthan Mohanathas
dcf1dc060a
Rename #[no_drop_flag] to #[unsafe_no_drop_flag]
2013-06-27 23:20:42 -04:00
Daniel Micay
779ee2a2dd
util: make NonCopyable 0 size (instead of 1 byte)
...
this also adds a derived Eq, TotalEq, Ord and TotalOrd along with
removing the useless constructor
2013-06-27 23:20:42 -04:00
bors
63afb8ccc8
auto merge of #7430 : huonw/rust/vec-kill, r=thestinger
2013-06-27 15:01:58 -07:00
bors
9b6dfb8578
auto merge of #7414 : gifnksm/rust/max_by, r=catamorphism
...
`max_by` method returns the element that gives the maximum value from the specfied function.
`max_by`/`min_by` are convenient when you want to get the value which has greatest/smallest scores.
Inspired by [ruby's Enumerable module](http://ruby-doc.org/core-2.0/Enumerable.html ).
2013-06-27 10:37:36 -07:00
Huon Wilson
366ca44cc8
std: silence some test warnings.
2013-06-28 01:45:24 +10:00
Huon Wilson
32d655916f
Convert vec::{reserve, reserve_at_least, capacity} to methods.
2013-06-28 00:40:47 +10:00
Huon Wilson
ae2f185349
Convert vec::{partition, partitioned} to methods.
2013-06-28 00:20:43 +10:00
Huon Wilson
206d4f00dc
Convert vec::retain to a method.
2013-06-28 00:20:42 +10:00
Huon Wilson
4470d14388
Convert vec::truncate to a method.
2013-06-28 00:20:42 +10: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
Huon Wilson
d2e3e1e52b
Convert vec::{head, tail, init, last} (and similar fns) to methods.
2013-06-27 22:37:00 +10:00
Huon Wilson
d0512b1055
Convert vec::[mut_]slice to methods, remove vec::const_slice.
2013-06-27 22:36:09 +10:00
bors
a28f9ba526
auto merge of #7361 : brson/rust/incoming, r=brson
2013-06-27 01:04:33 -07:00
bors
f1e09d6f1f
auto merge of #7420 : mozilla/rust/rollup, r=thestinger
2013-06-26 23:07:41 -07:00
Daniel Micay
9f5f609b1c
vec: remove superseded reverse_part function
...
`reverse(xs.mut_slice(a, b))` replaces `reverse_part(xs, a, b)`
2013-06-26 19:42:34 -04:00
Ben Blum
12e09afd6d
Work-around 'static bound requirement in io::with_bytes_reader (note: does not fix #5723 , interface still unsafe)
2013-06-26 18:14:43 -04:00
Kevin Ballard
3df37326cf
Add methods .move_from() and .copy_from() to vec
...
Add method .move_from() to MutableVector, which consumes another vector
and moves elements into the receiver.
Add new trait MutableCloneableVector with one method .copy_from(), which
clones elements from another vector into the receiver.
2013-06-26 18:12:29 -04:00
Kevin Ballard
524a92c72f
Add method .set_memory in vec::bytes for &[u8]
...
Add new trait vec::bytes::MutableByteVector which currently defines one
method .set_memory().
2013-06-26 18:11:18 -04:00
gifnksm
8edb8f6d39
iterator: Add IteratorUtil::max_by/min_by
method
2013-06-27 06:55:22 +09:00
bors
3433851a37
auto merge of #7345 : blake2-ppc/rust/iterator-flat-map, r=thestinger
...
flat_map_ produces an iterator that maps each element to an iterator,
and yields the elements of the produced iterators.
This is the monadic bind :: M a -> (a -> M b) -> M b for iterators.
Named just like the vec method, but with a trailing underline until the
method resolution bug is resolved.
We discussed the name chain_map, but I decided to go with flat_map_ for consistency with vec.
Since it.map(f).flatten() would be the same as it.flat_map(f), we could choose
to just implement a flatten method instead. Either way the possibilities are the same but flat_map is more convenient.
2013-06-26 09:47:16 -07:00
bors
4ec05e02fa
auto merge of #7216 : kballard/rust/task_rng, r=brson
2013-06-26 03:08:04 -07:00
bors
09b4525f84
auto merge of #7113 : alexcrichton/rust/banned-warnings, r=cmr
...
Reopening of #7031 , Closes #6963
I imagine though that this will bounce in bors once or twice... Because attributes can't be cfg(stage0)'d off, there's temporarily a lot of new stage0/stage1+ code.
2013-06-26 00:56:04 -07:00
bors
22408d9ad5
auto merge of #7269 : luqmana/rust/drop, r=thestinger
...
Finally rename finalize to drop.
Closes #4332 .
2013-06-25 20:29:06 -07:00
Brian Anderson
5d3ca4b843
Merge remote-tracking branch 'mozilla/master' into incoming
...
Conflicts:
src/librustc/middle/astencode.rs
src/librustc/middle/check_const.rs
2013-06-25 19:32:00 -07:00