about summary refs log tree commit diff
path: root/src/libstd
AgeCommit message (Collapse)AuthorLines
2013-08-20auto merge of #8519 : msullivan/rust/objects, r=catamorphismbors-1/+1
r?
2013-08-20auto merge of #8566 : toddaaro/rust/idle-opt+cleaning, r=catamorphism,brsonbors-302/+386
Instead of a furious storm of idle callbacks we just have one. This is a major performance gain - around 40% on my machine for the ping pong bench. Also in this PR is a cleanup commit for the scheduler code. Was previously up as a separate PR, but bors load + imminent merge hell led me to roll them together. Was #8549.
2013-08-19std: Restore dynamic borrow trackingBrian Anderson-17/+43
2013-08-19Try to fix mac valgrind bot by disabling thread-heavy activities.Graydon Hoare-15/+64
2013-08-19auto merge of #8459 : thestinger/rust/checked, r=graydonbors-2/+42
2013-08-19clean whitespace :/toddaaro-6/+6
2013-08-19Rangechange the log message truncation limit.Michael Sullivan-1/+1
2013-08-19auto merge of #8535 : nikomatsakis/rust/issue-3678-wrappers-be-gone-2, r=graydonbors-48/+489
Long-standing branch to remove foreign function wrappers altogether. Calls to C functions are done "in place" with no stack manipulation; the scheme relies entirely on the correct use of `#[fixed_stack_segment]` to guarantee adequate stack space. A linter is added to detect when `#[fixed_stack_segment]` annotations are missing. An `externfn!` macro is added to make it easier to declare foreign fns and wrappers in one go: this macro may need some refinement, though, for example it might be good to be able to declare a group of foreign fns. I leave that for future work (hopefully somebody else's work :) ). Fixes #3678.
2013-08-19Add externfn macro and correctly label fixed_stack_segmentsNiko Matsakis-48/+489
2013-08-19auto merge of #8564 : alexcrichton/rust/ifmt+++, r=graydonbors-4/+58
See discussion in #8489, but this selects option 3 by adding a `Default` trait to be implemented by various basic types. Once this makes it into a snapshot I think it's about time to start overhauling all current use-cases of `fmt!` to move towards `ifmt!`. The goal is to replace `%X` with `{}` in 90% of situations, and this commit should enable that.
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-18auto merge of #8560 : kballard/rust/reserve-yield, r=pcwaltonbors-32/+32
Rename task::yield() to task::deschedule(). Fixes #8494.
2013-08-18auto merge of #8545 : blake2-ppc/rust/iterbytes, r=alexcrichtonbors-61/+89
Address issue #5257, for example these values all had the same hash value: ("aaa", "bbb", "ccc") ("aaab", "bb", "ccc") ("aaabbb", "", "ccc") IterBytes for &[A] now includes the length, before calling iter_bytes on each element. IterBytes for &str is now terminated by a byte that does not appear in UTF-8. This way only one more byte is processed when hashing strings.
2013-08-18auto merge of #8558 : kballard/rust/xorshift-seed, r=cmrbors-6/+15
Fixes #8359.
2013-08-18std::hash: Add testcase for colliding hashes of tuplesblake2-ppc-0/+14
Add a testcase that verifies that (s, t) and (u, v) don't collide even if s + t == u + v (concatenation).
2013-08-18std::to_bytes: Implement IterBytes on 1- to 8-tuplesblake2-ppc-20/+29
2013-08-18std::to_bytes: Delimit sequences &[A] and ~str when hashingblake2-ppc-42/+47
Address issue #5257, for example these values all had the same hash value: ("aaa", "bbb", "ccc") ("aaab", "bb", "ccc") ("aaabbb", "", "ccc") IterBytes for &[A] now includes the length, before calling iter_bytes on each element. IterBytes for &str is now terminated by a byte that does not appear in UTF-8. This way only one more byte is processed when hashing strings.
2013-08-18auto merge of #8555 : chris-morgan/rust/time-clone, r=huonwbors-1/+15
I need `Clone` for `Tm` for my latest work on [rust-http](https://github.com/chris-morgan/rust-http) (static typing for headers, and headers like `Date` are a time), so here it is. @huonw recommended deriving DeepClone while I was at it. I also had to implement `DeepClone` for `~str` to get a derived implementation of `DeepClone` for `Tm`; I did `@str` while I was at it, for consistency.
2013-08-18auto merge of #8551 : huonw/rust/speling, r=alexcrichtonbors-58/+59
(This doesn't add/remove `u`s or change `ize` to `ise`, or anything like that.)
2013-08-18More spelling corrections.Huon Wilson-7/+9
2013-08-17auto merge of #8433 : brson/rust/rm-more-oldrt-crud, r=brsonbors-5/+0
Just deleting more stuff.
2013-08-17Fix warnings in testsErick Tryzelaar-1/+1
2013-08-16A round of code cleaning for the primary scheduler code. Comments have been ↵toddaaro-275/+201
updated, a minor amount of support type restructing has happened, methods have been reordered, and some duplicate code has been purged.
2013-08-16Moved the logic for a pausible idle callback into a new type - ↵toddaaro-96/+103
PausibleIdleCallback and placed the appropriate signatures in rtio and implementation into uvio.
2013-08-16std::rt: Fix a race in UvRemoteCallback's dtor that misses callbacksBrian Anderson-7/+74
Full description in comments.
2013-08-16std::rt: Touch up idle logicBrian Anderson-16/+36
2013-08-16an attempt at a singleton pausible idle callback for each scheduler. suffers ↵toddaaro-19/+83
from nondeterministic deadlock and also pending scheduler messages on scheduler shutdown.
2013-08-16Delegate `{}` to Default instead of PolyAlex Crichton-1/+55
By using a separate trait this is overridable on a per-type basis and makes room for the possibility of even more arguments passed in for the future.
2013-08-16Implement `{:s}` for ~str and @str as wellAlex Crichton-3/+3
2013-08-16Reserve 'yield' keywordKevin Ballard-32/+32
Rename task::yield() to task::deschedule(). Fixes #8494.
2013-08-16Remove the annihilate lang itemBrian Anderson-5/+0
2013-08-16Give XorShiftRng::new() a random seedKevin Ballard-6/+15
Fixes #8359.
2013-08-16auto merge of #8534 : huonw/rust/tls-key-macro, r=alexcrichtonbors-2/+2
This allows the internal implementation details of the TLS keys to be changed without requiring the update of all the users. (Or, applying changes that *have* to be applied for the keys to work correctly, e.g. forcing LLVM to not merge these constants.)
2013-08-16auto merge of #8532 : kballard/rust/cstr-cleanup, r=ericktbors-66/+185
Implement interior null checking in `.to_c_str()`, among other changes.
2013-08-16Implement DeepClone for str types.Chris Morgan-1/+15
2013-08-16auto merge of #8526 : blake2-ppc/rust/either-result, r=catamorphismbors-82/+115
Retry of PR #8471 Replace the remaining functions marked for issue #8228 with similar functions that are iterator-based. Change `either::{lefts, rights}` to be iterator-filtering instead of returning a vector. Replace `map_vec`, `map_vec2`, `iter_vec2` in std::result with three functions: * `result::collect` gathers `Iterator<Result<V, U>>` to `Result<~[V], U>` * `result::fold` folds `Iterator<Result<T, E>>` to `Result<V, E>` * `result::fold_` folds `Iterator<Result<T, E>>` to `Result<(), E>`
2013-08-15auto merge of #8518 : catamorphism/rust/issue-8498-workaround, r=brsonbors-10/+10
r? @brson
2013-08-16doc: convert remaining uses of core:: to std::.Huon Wilson-21/+21
2013-08-16doc: correct spelling in documentation.Huon Wilson-30/+29
2013-08-16syntax: add a local_data_key macro that creates a key for access to the TLS.Huon Wilson-2/+2
This allows the internal implementation details of the TLS keys to be changed without requiring the update of all the users. (Or, applying changes that have to be applied for the keys to work correctly, e.g. forcing LLVM to not merge these constants.)
2013-08-15vec: rm redundant is_empty implementationsDaniel Micay-12/+0
2013-08-15iterator: cleanupDaniel Micay-4/+3
2013-08-15vec: rm obsolete zip and zip_sliceDaniel Micay-41/+1
These are obsoleted by the generic iterator `zip` adaptor. Unlike these, it does not clone the elements or allocate a new vector by default.
2013-08-15tuple: remove obsolete ExtendedTupleOpsDaniel Micay-53/+1
replaced by iterators (generic composable `map` and `zip` adaptors)
2013-08-15kinds: update documentationDaniel Micay-9/+3
2013-08-15ptr: inline the Clone implementationDaniel Micay-0/+1
2013-08-15auto merge of #8485 : alexcrichton/rust/add-tests, r=catamorphismbors-1/+1
Closes #3907 Closes #5493 Closes #4464 Closes #4759 Closes #5666 Closes #5884 Closes #5926 Closes #6318 Closes #6557 Closes #6898 Closes #6919 Closes #7222
2013-08-15Fix a typo in the ifmt doxAlex Crichton-1/+1
2013-08-15auto merge of #8515 : kballard/rust/saturating-checked, r=thestingerbors-38/+25
r? @thestinger
2013-08-15Fix select deschedule environment race for real this time, in light of task ↵Ben Blum-18/+23
killing.