about summary refs log tree commit diff
path: root/src/libstd/select.rs
AgeCommit message (Collapse)AuthorLines
2013-11-26librustc: Fix merge fallout.Patrick Walton-1/+1
2013-11-26test: Remove non-procedure uses of `do` from compiletest, libstd tests,Patrick Walton-3/+3
compile-fail tests, run-fail tests, and run-pass tests.
2013-11-26libstd: Remove all non-`proc` uses of `do` from libstdPatrick Walton-4/+4
2013-11-24Remove linked failure from the runtimeAlex Crichton-79/+29
The reasons for doing this are: * The model on which linked failure is based is inherently complex * The implementation is also very complex, and there are few remaining who fully understand the implementation * There are existing race conditions in the core context switching function of the scheduler, and possibly others. * It's unclear whether this model of linked failure maps well to a 1:1 threading model Linked failure is often a desired aspect of tasks, but we would like to take a much more conservative approach in re-implementing linked failure if at all. Closes #8674 Closes #8318 Closes #8863
2013-10-28Make some more rt components publicAlex Crichton-1/+3
Primarily this makes the Scheduler and all of its related interfaces public. The reason for doing this is that currently any extern event loops had no access to the scheduler at all. This allows third-party event loops to manipulate the scheduler, along with allowing the uv event loop to live inside of its own crate.
2013-10-24Implement a basic event loop built on LittleLockAlex Crichton-10/+10
It's not guaranteed that there will always be an event loop to run, and this implementation will serve as an incredibly basic one which does not provide any I/O, but allows the scheduler to still run. cc #9128
2013-10-22Drop the '2' suffix from logging macrosAlex Crichton-3/+3
Who doesn't like a massive renaming?
2013-10-15Require module documentation with missing_docAlex Crichton-0/+2
Closes #9824
2013-10-07Fix existing privacy/visibility violationsAlex Crichton-3/+1
This commit fixes all of the fallout of the previous commit which is an attempt to refine privacy. There were a few unfortunate leaks which now must be plugged, and the most horrible one is the current `shouldnt_be_public` module now inside `std::rt`. I think that this either needs a slight reorganization of the runtime, or otherwise it needs to just wait for the external users of these modules to get replaced with their `rt` implementations. Other fixes involve making things pub which should be pub, and otherwise updating error messages that now reference privacy instead of referencing an "unresolved name" (yay!).
2013-09-30std: Remove usage of fmt!Alex Crichton-3/+3
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.