about summary refs log tree commit diff
path: root/src/liballoc/raw_vec.rs
AgeCommit message (Collapse)AuthorLines
2020-04-01Add missing allocation guard in `RawVec::grow`Tim Diekmann-0/+1
2020-03-28Make fields in `MemoryBlock` publicTim Diekmann-4/+4
2020-03-26Remove alignment from `MemoryBlock`Tim Diekmann-23/+19
2020-03-26Fix safety section of `RawVec::into_box`Tim Diekmann-1/+2
2020-03-26Fix wording in `RawVec::from_raw_parts(_in)`Tim Diekmann-2/+2
2020-03-26Remove check for ZST in `RawVec::needs_to_grow`Tim Diekmann-2/+1
2020-03-26Refine docs for `RawVec::from_raw_parts(_in)`Tim Diekmann-4/+6
2020-03-26Remove the note on the internal capacity field in `RawVec`Tim Diekmann-3/+1
2020-03-26Fix assertion in `shrink` to use `capacity()` insteadTim Diekmann-1/+1
2020-03-26Fix comment in `RawVec::into_box()`Tim Diekmann-1/+1
2020-03-26Fix ZST handling for `RawVec`Tim Diekmann-6/+6
2020-03-26Fix issues from review and unsoundness of `RawVec::into_box`Tim Diekmann-114/+114
2020-03-26Overhaul of the `AllocRef` trait to match allocator-wg's latest consensTim Diekmann-347/+221
2020-03-08Allow ZSTs in `AllocRef`Tim Diekmann-20/+18
2020-03-03Remove `usable_size` APIsTim Diekmann-8/+13
2020-02-10Remove common usage pattern from `AllocRef`Tim Diekmann-6/+7
2020-01-27Rename `Alloc` to `AllocRef`Tim Diekmann-8/+8
2019-12-22Format the worldMark Rousskov-71/+55
2019-12-21Require issue = "none" over issue = "0" in unstable attributesRoss MacArthur-1/+1
2019-12-18no need to bootstrapMark Mansi-8/+1
2019-12-18add fixmeMark Mansi-0/+1
2019-12-18fix importMark Mansi-1/+1
2019-12-18use usize::MAX instead of !0Mark Mansi-1/+1
2019-12-18remove a bit more hackeryMark Mansi-41/+8
2019-12-18Remove a const-if-hack in RawVecMark Mansi-8/+32
2019-09-16Const-stabilize `Vec::new`.Mazdak Farrokhzad-1/+26
2019-09-14Update src/liballoc/raw_vec.rsAlexander Regueiro-1/+1
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-09-06A few cosmetic improvements to code & comments in liballoc and libcoreAlexander Regueiro-76/+74
2019-08-16Add the Layout of the failed allocation to TryReserveError::AllocErrorSimon Sapin-9/+11
… and add a separately-unstable field to force non-exhaustive matching (`#[non_exhaustive]` is no implemented yet on enum variants) so that we have the option to later expose the allocator’s error value. CC https://github.com/rust-lang/wg-allocators/issues/23
2019-08-16Rename CollectionAllocError to TryReserveErrorSimon Sapin-6/+6
2019-08-02liballoc: Unconfigure tests during normal buildVadim Petrochenkov-79/+3
Remove additional libcore-like restrictions from liballoc, turns out the testing works ok if the tests are a part of liballoc itself.
2019-07-25Auto merge of #60340 - mgeier:cap-vs-capacity, r=alexcrichtonbors-59/+60
Rename .cap() methods to .capacity() As mentioned in #60316, there are a few `.cap()` methods, which seem out-of-place because such methods are called `.capacity()` in the rest of the code. This PR renames them to `.capacity()` but leaves `RawVec::cap()` in there for backwards compatibility. I didn't try to mark the old version as "deprecated", because I guess this would cause too much noise.
2019-06-25Remove RawVec::cap()Matthias Geier-6/+0
As suggested in https://github.com/rust-lang/rust/pull/60340#issuecomment-493681032
2019-05-27avoid materializing unintialized Boxes in RawVecAleksey Kladov-4/+6
2019-04-27Rename .cap() methods to .capacity()Matthias Geier-59/+66
... but leave the old names in there for backwards compatibility.
2019-04-12Stabilize the `alloc` crate.Simon Sapin-2/+2
This implements RFC 2480: * https://github.com/rust-lang/rfcs/pull/2480 * https://github.com/rust-lang/rfcs/blob/master/text/2480-liballoc.md Closes https://github.com/rust-lang/rust/issues/27783
2019-02-10libs: doc commentsAlexander Regueiro-2/+2
2019-02-03liballoc: revert nested imports style changes.Mazdak Farrokhzad-13/+9
2019-02-02liballoc: apply uniform_paths.Mazdak Farrokhzad-2/+2
2019-02-02liballoc: adjust abolute imports + more import fixes.Mazdak Farrokhzad-1/+1
2019-02-02liballoc: refactor & fix some imports.Mazdak Farrokhzad-11/+14
2019-02-02liballoc: cargo check passes on 2018Mazdak Farrokhzad-5/+5
2019-01-08RawVec doesn't always abort on allocation errorsJonathan Behrens-1/+1
2018-12-25Remove licensesMark Rousskov-10/+0
2018-12-07Various minor/cosmetic improvements to codeAlexander Regueiro-1/+1
2018-11-13fix various typos in doc commentsAndy Russell-1/+1
2018-08-21Rollup merge of #53329 - frewsxcv:frewsxcv-ptr-add-sub, r=RalfJungkennytm-2/+2
Replace usages of ptr::offset with ptr::{add,sub}. Rust provides these helper methods – so let's use them!
2018-08-20Replace usages of ptr::offset with ptr::{add,sub}.Corey Farwell-2/+2
2018-08-19Fix typos found by codespell.Matthias Krüger-1/+1
2018-06-29Move core::alloc::CollectionAllocErr to alloc::collectionsSimon Sapin-2/+2