summary refs log tree commit diff
path: root/src/libstd/select.rs
AgeCommit message (Collapse)AuthorLines
2013-09-09auto merge of #9062 : blake2-ppc/rust/vec-iterator, r=alexcrichtonbors-4/+4
Visit the free functions of std::vec and reimplement or remove some. Most prominently, remove `each_permutation` and replace with two iterators, ElementSwaps and Permutations. Replace unzip, unzip_slice with an updated `unzip` that works with an iterator argument. Replace each_permutation with a Permutation iterator. The new permutation iterator is more efficient since it uses an algorithm that produces permutations in an order where each is only one element swap apart, including swapping back to the original state with one swap at the end. Unify the seldomly used functions `build`, `build_sized`, `build_sized_opt` into just one function `build`. Remove `equal_sizes`
2013-09-10std::vec: Change fn unzip to take an iterator argumentblake2-ppc-4/+4
Remove unzip_slice since it's redundant. Old unzip is equivalent to the `|x| unzip(x.move_iter())`
2013-09-09rename `std::iterator` to `std::iter`Daniel Micay-2/+2
The trait will keep the `Iterator` naming, but a more concise module name makes using the free functions less verbose. The module will define iterables in addition to iterators, as it deals with iteration in general.
2013-08-30std::select: Use correct indices from the frontblake2-ppc-2/+2
Caught a bug where .enumerate() was used on a reverse iterator. The indices should be counted from the front here (bblum confirms).
2013-08-29Remove the iter module.Jason Fager-1/+1
Moves the Times trait to num while the question of whether it should exist at all gets hashed out as a completely separate question.
2013-08-27librustc: Ensure that type parameters are in the right positions in paths.Patrick Walton-1/+1
This removes the stacking of type parameters that occurs when invoking trait methods, and fixes all places in the standard library that were relying on it. It is somewhat awkward in places; I think we'll probably want something like the `Foo::<for T>::new()` syntax.
2013-08-22Enabled unit tests in std and extra.Vadim Chugunov-2/+2
2013-08-18auto merge of #8565 : bblum/rust/select-bugfix, r=brsonbors-18/+23
@brson grilled me about how this bugfix worked the first time around, and it occurred to me that it didn't in the case where the task is unwinding. Now it will.
2013-08-16Reserve 'yield' keywordKevin Ballard-2/+2
Rename task::yield() to task::deschedule(). Fixes #8494.
2013-08-15Fix select deschedule environment race for real this time, in light of task ↵Ben Blum-18/+23
killing.
2013-08-12Fix select() in light of the deschedule...and then race. Close #8347.Ben Blum-0/+20
2013-08-12Reorganise Select traits to not expose internal runtime types. Close #5160. ↵Ben Blum-0/+324
Pending #8215.