about summary refs log tree commit diff
path: root/src/libstd/collections
AgeCommit message (Collapse)AuthorLines
2015-02-09std: Rename IntoIterator::Iter to IntoIterAlex Crichton-5/+5
This is in preparation for stabilization of the `IntoIterator` trait. All implementations and references to `Iter` need to be renamed to `IntoIter`. [breaking-change]
2015-02-06make `IndexMut` a super trait over `Index`Jorge Aparicio-2/+0
closes #21630
2015-02-07fix outdated docsAlexis-28/+28
Conflicts: src/libstd/collections/mod.rs
2015-02-07fix outdated docsAlexis-9/+9
Conflicts: src/libstd/collections/mod.rs
2015-02-06More libcollections fixesManish Goregaokar-3/+3
2015-02-06Rollup merge of #21969 - Gankro:collections-cleanup, r=alexcrichtonManish Goregaokar-124/+124
This is 99% burning ints to the ground, but I also got rid of useless annotations or made code more \"idiomatic\" as I went along. Mostly changes in tests.
2015-02-06Rollup merge of #21925 - sfackler:allow-missing-copy, r=alexcrichtonManish Goregaokar-2/+0
This was particularly helpful in the time just after OIBIT's implementation to make sure things that were supposed to be Copy continued to be, but it's now creates a lot of noise for types that intentionally don't want to be Copy. r? @alexcrichton
2015-02-06Rollup merge of #21951 - Gankro:entry, r=aturonManish Goregaokar-8/+8
This also removes two erroneous re-exports of the Entry variants, and so is incidentally a [breaking-change], though presumably no one should have been using those. r? @aturon
2015-02-05misc collections code cleanupAlexis-124/+124
2015-02-04Fix for misspelled comments.Joseph Crail-1/+1
The spelling corrections were made in both documentation comments and regular comments.
2015-02-04stabilize core Entry APIAlexis-8/+8
2015-02-04Auto merge of #21892 - huonw:deprecate-rand, r=alexcrichtonbors-0/+1
Use [`rand`](https://crates.io/crates/rand) and [`derive_rand`](https://crates.io/crates/derive_rand) from crates.io. [breaking-change]
2015-02-03Switch missing_copy_implementations to default-allowSteven Fackler-2/+0
This was particularly helpful in the time just after OIBIT's implementation to make sure things that were supposed to be Copy continued to be, but it's now creates a lot of noise for types that intentionally don't want to be Copy.
2015-02-04Deprecate in-tree `rand`, `std::rand` and `#[derive(Rand)]`.Huon Wilson-0/+1
Use the crates.io crate `rand` (version 0.1 should be a drop in replacement for `std::rand`) and `rand_macros` (`#[derive_Rand]` should be a drop-in replacement). [breaking-change]
2015-02-03Auto merge of #21745 - chris-morgan:add-missing-unstable-attributes, r=huonwbors-0/+5
I’d kind of like to be able to use HashState in AnyMap, which I can’t do without a stability attribute on it. While I was at it I looked around and found a few more missing.
2015-02-02rollup merge of #21842: alexcrichton/issue-21839Alex Crichton-16/+6
Now that associated types are fully implemented the iterator adaptors only need type parameters which are associated with actual storage. All other type parameters can either be derived from these (e.g. they are an associated type) or can be bare on the `impl` block itself. This is a breaking change due to the removal of type parameters on these iterator adaptors, but code can fairly easily migrate by just deleting the relevant type parameters for each adaptor. Other behavior should not be affected. Closes #21839 [breaking-change]
2015-02-02remove unused mut qualifiersJorge Aparicio-3/+3
2015-02-02`for x in xs.iter()` -> `for x in &xs`Jorge Aparicio-5/+5
2015-02-02impl IntoIterator for HashSetJorge Aparicio-1/+27
2015-02-02impl IntoIterator for HashMapJorge Aparicio-1/+37
2015-02-01std: Remove extra type params on iter adaptorsAlex Crichton-16/+6
Now that associated types are fully implemented the iterator adaptors only need type parameters which are associated with actual storage. All other type parameters can either be derived from these (e.g. they are an associated type) or can be bare on the `impl` block itself. This is a breaking change due to the removal of type parameters on these iterator adaptors, but code can fairly easily migrate by just deleting the relevant type parameters for each adaptor. Other behavior should not be affected. Closes #21839 [breaking-change]
2015-02-01Auto merge of #21811 - tbu-:pr_more_isize, r=alexcrichtonbors-2/+2
Remove more `isize` stuff. Also fix the manual a bit about integer inference.
2015-01-31make Send/Sync impl of RawTable manualAlexis-12/+14
2015-01-31Kill more `isize`sTobias Bucher-2/+2
2015-01-30rollup merge of #21631: tbu-/isize_policeAlex Crichton-89/+89
Conflicts: src/libcoretest/iter.rs
2015-01-30smoke out remaining bugsJorge Aparicio-2/+1
2015-01-30fix testsJorge Aparicio-0/+1
2015-01-30fix falloutJorge Aparicio-2/+2
2015-01-30Add a few missing stability markers.Chris Morgan-0/+5
2015-01-30Remove all `i` suffixesTobias Bucher-89/+89
2015-01-29fix inference falloutJorge Aparicio-6/+6
2015-01-29convert remaining `range(a, b)` to `a..b`Jorge Aparicio-1/+1
2015-01-29`for x in range(a, b)` -> `for x in a..b`Jorge Aparicio-27/+27
sed -i 's/in range(\([^,]*\), *\([^()]*\))/in \1\.\.\2/g' **/*.rs
2015-01-29`range(a, b).foo()` -> `(a..b).foo()`Jorge Aparicio-3/+3
sed -i 's/ range(\([^,]*\), *\([^()]*\))\./ (\1\.\.\2)\./g' **/*.rs
2015-01-25Merge remote-tracking branch 'rust-lang/master'Brian Anderson-36/+86
Conflicts: mk/tests.mk src/liballoc/arc.rs src/liballoc/boxed.rs src/liballoc/rc.rs src/libcollections/bit.rs src/libcollections/btree/map.rs src/libcollections/btree/set.rs src/libcollections/dlist.rs src/libcollections/ring_buf.rs src/libcollections/slice.rs src/libcollections/str.rs src/libcollections/string.rs src/libcollections/vec.rs src/libcollections/vec_map.rs src/libcore/any.rs src/libcore/array.rs src/libcore/borrow.rs src/libcore/error.rs src/libcore/fmt/mod.rs src/libcore/iter.rs src/libcore/marker.rs src/libcore/ops.rs src/libcore/result.rs src/libcore/slice.rs src/libcore/str/mod.rs src/libregex/lib.rs src/libregex/re.rs src/librustc/lint/builtin.rs src/libstd/collections/hash/map.rs src/libstd/collections/hash/set.rs src/libstd/sync/mpsc/mod.rs src/libstd/sync/mutex.rs src/libstd/sync/poison.rs src/libstd/sync/rwlock.rs src/libsyntax/feature_gate.rs src/libsyntax/test.rs
2015-01-23grandfathered -> rust1Brian Anderson-95/+95
2015-01-23Set unstable feature names appropriatelyBrian Anderson-19/+19
* `core` - for the core crate * `hash` - hashing * `io` - io * `path` - path * `alloc` - alloc crate * `rand` - rand crate * `collections` - collections crate * `std_misc` - other parts of std * `test` - test crate * `rustc_private` - everything else
2015-01-22Rollup merge of #21217 - Gankro:docadoca, r=steveklabnikSteve Klabnik-2/+52
Not sure on what *exactly* should be said here, but I think this is the most important bit. This PR also establishes conventions for describing performance minimally. I suggest to describe preformance for individual methods we use a `# Performance` heading. Not sure if we should have ``` # Performance: O(1) details details ``` or ``` # Performance: O(1) details details ``` Since I think most methods don't need discussion, the former seems more resonable. But it's kind of weird to have info "in" the heading. r? @steveklabnik
2015-01-21Remove 'since' from unstable attributesBrian Anderson-19/+19
2015-01-21Tie stability attributes to feature gatesBrian Anderson-1/+0
2015-01-21Add 'feature' and 'since' to stability attributesBrian Anderson-114/+128
2015-01-21rollup merge of #21457: alexcrichton/issue-21436Alex Crichton-11/+11
Conflicts: src/liballoc/boxed.rs src/librustc/middle/traits/error_reporting.rs src/libstd/sync/mpsc/mod.rs
2015-01-21rollup merge of #21419: Toby-S/patch-1Alex Crichton-23/+23
This just corrects a couple of typos in doc comments, and changes some to conform to the Rust guidelines.
2015-01-20std: Rename Show/String to Debug/DisplayAlex Crichton-11/+11
This commit is an implementation of [RFC 565][rfc] which is a stabilization of the `std::fmt` module and the implementations of various formatting traits. Specifically, the following changes were performed: [rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0565-show-string-guidelines.md * The `Show` trait is now deprecated, it was renamed to `Debug` * The `String` trait is now deprecated, it was renamed to `Display` * Many `Debug` and `Display` implementations were audited in accordance with the RFC and audited implementations now have the `#[stable]` attribute * Integers and floats no longer print a suffix * Smart pointers no longer print details that they are a smart pointer * Paths with `Debug` are now quoted and escape characters * The `unwrap` methods on `Result` now require `Display` instead of `Debug` * The `Error` trait no longer has a `detail` method and now requires that `Display` must be implemented. With the loss of `String`, this has moved into libcore. * `impl<E: Error> FromError<E> for Box<Error>` now exists * `derive(Show)` has been renamed to `derive(Debug)`. This is not currently warned about due to warnings being emitted on stage1+ While backwards compatibility is attempted to be maintained with a blanket implementation of `Display` for the old `String` trait (and the same for `Show`/`Debug`) this is still a breaking change due to primitives no longer implementing `String` as well as modifications such as `unwrap` and the `Error` trait. Most code is fairly straightforward to update with a rename or tweaks of method calls. [breaking-change] Closes #21436
2015-01-21Rollup merge of #21375 - petrochenkov:ssbsl, r=alexcrichtonBarosl LEE-13/+10
After PR #19766 added implicit coersions `*mut T -> *const T`, the explicit casts can be removed. (The number of such casts turned out to be relatively small).
2015-01-21Rollup merge of #21302 - gutworth:rm-find-equiv-test, r=brsonBarosl LEE-17/+0
2015-01-20Correct small typos in map.rs.Toby Scrace-23/+23
This just corrects a couple of typos in doc comments, and changes some to conform to the Rust guidelines.
2015-01-19Implement range and range_mut for BTreePiotr Czarnecki-0/+1
Simplify BTree's iterators, too.
2015-01-17remove test_find_equiv, since find_equiv doesn't exist anymoreBenjamin Peterson-17/+0
2015-01-17Remove unnecessary explicit conversions to *const Twe-13/+10