summary refs log tree commit diff
path: root/src/libcollections/tests
AgeCommit message (Collapse)AuthorLines
2017-06-03Auto merge of #42331 - retep998:standard-relocation-coupon, r=alexcrichtonbors-0/+17
Improve reallocation in alloc_system on Windows Fixes https://github.com/rust-lang/rust/issues/42025
2017-06-02Rollup merge of #42310 - scottmcm:deprecate-range-stepby, r=alexcrichtonMark Simulacrum-2/+3
Deprecate range-specific `step_by` Deprecation attributes and test updates only. Was replaced by an any-iterator version in https://github.com/rust-lang/rust/pull/41439 Last follow-up (this release) to https://github.com/rust-lang/rust/pull/42110#issuecomment-303210138 r? @alexcrichton
2017-06-02Add test for vecs with overaligned dataPeter Atashian-0/+17
2017-06-02Auto merge of #41670 - scottmcm:slice-rotate, r=alexcrichtonbors-0/+36
Add an in-place rotate method for slices to libcore A helpful primitive for moving chunks of data around inside a slice. For example, if you have a range selected and are drag-and-dropping it somewhere else (Example from [Sean Parent's talk](https://youtu.be/qH6sSOr-yk8?t=560)). (If this should be an RFC instead of a PR, please let me know.) Edit: changed example
2017-06-01tests: fix fallout from empowering unused_allocation in comparisons.Eduard-Mihai Burtescu-6/+6
2017-05-31Avoid range::step_by in another testScott McMurray-2/+3
2017-05-21Stop returning k from [T]::rotateScott McMurray-2/+1
2017-05-21Add an in-place rotate method for slices to libcoreScott McMurray-0/+37
A helpful primitive for moving chunks of data around inside a slice. In particular, adding elements to the end of a Vec then moving them somewhere else, as a way to do efficient multiple-insert. (There's drain for efficient block-remove, but no easy way to block-insert.) Talk with another example: <https://youtu.be/qH6sSOr-yk8?t=560>
2017-05-20Stabilize library features for 1.18.0Steven Fackler-1/+0
Closes #38863 Closes #38980 Closes #38903 Closes #36648
2017-05-04Make [u8]::reverse() 5x fasterScott McMurray-0/+10
Since LLVM doesn't vectorize the loop for us, do unaligned reads of a larger type and use LLVM's bswap intrinsic to do the reversing of the actual bytes. cfg!-restricted to x86 and x86_64, as I assume it wouldn't help on things like ARMv5. Also makes [u16]::reverse() a more modest 1.5x faster by loading/storing u32 and swapping the u16s with ROT16. Thank you ptr::*_unaligned for making this easy :)
2017-04-24Add Splice forget testMatt Ickstadt-0/+15
2017-04-23Improve splice docs and testsMatt Ickstadt-1/+94
2017-04-23Add Vec::splice and String::spliceSimon Sapin-0/+19
2017-04-20Remove BinaryHeap::{push_pop,replace}Josh Stone-38/+0
[unstable, deprecated since 1.13.0]
2017-04-20Auto merge of #41191 - seanmonstar:spec-extend-vec-intoiter, r=alexcrichtonbors-0/+22
specialize Extend for Vec with IntoIter Before, `vec.extend(&other_vec)` was quite a bit faster than `vec.extend(other_vec)`. This allows extending by consuming a vec to use the same code as extending from a slice.
2017-04-19specialize Extend for Vec with IntoIterSean McArthur-0/+22
2017-04-12Add ToOwned::clone_into (unstable as toowned_clone_into)Scott McMurray-0/+10
to_owned generalizes clone; this generalizes clone_from. Use to_owned to give it a default impl. Customize the impl for [T], str, and T:Clone. Use it in Cow::clone_from to reuse resources when cloning Owned into Owned.
2017-04-03Move libXtest into libX/testsStjepan Glavina-0/+6847
This change moves: 1. `libcoretest` into `libcore/tests` 2. `libcollectionstest` into `libcollections/tests` This is a follow-up to #39561.