about summary refs log tree commit diff
path: root/src/libcore
AgeCommit message (Collapse)AuthorLines
2019-04-17Rollup merge of #60018 - RalfJung:miri-test-libstd, r=oli-obkMazdak Farrokhzad-4/+13
Miri now supports entropy, but is still slow Adjust the `cfg` and their comments in the test suites accordingly.
2019-04-17test sort_unstable in MiriRalf Jung-3/+12
2019-04-16implement nth_back for EnumerateAdrian Friedli-0/+28
2019-04-16implement nth_back for FuseAdrian Friedli-0/+16
2019-04-16implement nth_back for BytesAdrian Friedli-0/+5
2019-04-16Miri now supports entropy, but is still slowRalf Jung-2/+2
2019-04-16Fix the max value of usize on 16-bit platformsJakub Kądziołka-1/+1
2019-04-16Rollup merge of #59717 - Reconcyl:master, r=steveklabnikMazdak Farrokhzad-4/+3
improve docs for std::hint::unreachable_unchecked() Fixes #59549
2019-04-15Rollup merge of #59955 - RalfJung:stdsimd, r=alexcrichtonMazdak Farrokhzad-1/+1
bump stdsimd; make intra_doc_link_resolution_failure an error again; make lints more consistent I made `intra_doc_link_resolution_failure` warn so that it would properly respect `deny-warnings = false` in `config.toml`. `#[warn]` still become errors with `-D warnings` so I thought this was fine. Turns out however that we don't pass `-D warnings` when running rustdoc, so for additional rustdoc-lints we need to set them to `deny`. Also sue the opportunity to make the lint flags more consistent between libcore, liballoc, libstd. Cc @gnzlbg for the *big* stdsimd update.
2019-04-15Rollup merge of #59648 - alex:must-use-result, r=alexcrichtonMazdak Farrokhzad-0/+4
Add must_use annotations to Result::is_ok and is_err Discussed in #59610
2019-04-15Hasher: replace unsafe trasmute with to_ne_bytesStepan Koltsov-14/+10
Spead the knowledge of `to_ne_bytes` functions existence.
2019-04-14Rollup merge of #59900 - czipperz:remove-bracket-mut-syntax-in-pin-docs, ↵Mazdak Farrokhzad-12/+16
r=RalfJung Remove [mut] syntax in pin docs Resolves #59832
2019-04-14bump stdsimd; make intra_doc_link_resolution_failure an error againRalf Jung-1/+1
2019-04-13Fix stray ` in previous changeChris Gregory-1/+1
2019-04-13Escape &str in convert docsChris Gregory-2/+3
2019-04-14Rollup merge of #59925 - solson:split_ascii_whitespace-docfix, r=CentrilMazdak Farrokhzad-1/+1
Fix paste error in split_ascii_whitespace docs. It was accidentally still testing the unicode version, `split_whitespace`.
2019-04-14Rollup merge of #59912 - RalfJung:maybe-uninit, r=CentrilMazdak Farrokhzad-34/+0
MaybeUninit: remove deprecated functions
2019-04-13Expand note on mutable referencesChris Gregory-1/+4
2019-04-13Reorder blank lines in AsMut documentationChris Gregory-1/+2
2019-04-13Fix equivalent string in escape_defaultDaniel Luz-1/+1
2019-04-13Remove blank lines in AsRef documentationChris Gregory-2/+0
2019-04-13Remove broken links to self in Into documentationChris Gregory-4/+4
2019-04-13Remove dangling ` in Into documentationChris Gregory-1/+1
2019-04-12Fix paste error in split_ascii_whitespace docs.Scott Olson-1/+1
2019-04-12Auto merge of #59733 - cramertj:wake-by-ref, r=withoutboatsbors-11/+49
Final (one can only hope) futures_api adjustments Based on https://github.com/rust-lang/rust/pull/59119 -- this change is only the latter two commits. cc https://github.com/rust-lang/rust/issues/59725 r? @withoutboats
2019-04-12MaybeUninit: remove deprecated functionsRalf Jung-34/+0
2019-04-12Rollup merge of #59880 - solson:transmute-float, r=alexcrichtonMazdak Farrokhzad-10/+0
Remove note about transmute for float bitpatterns. This particular usecase has been safely abstracted in these `std` functions: [f32::to_bits](https://doc.rust-lang.org/std/primitive.f32.html#method.to_bits), [f32::from_bits](https://doc.rust-lang.org/std/primitive.f32.html#method.from_bits), [f64::to_bits](https://doc.rust-lang.org/std/primitive.f64.html#method.to_bits), [f64::from_bits](https://doc.rust-lang.org/std/primitive.f64.html#method.from_bits). So, I think we shouldn't recommend an unnecessary use of `unsafe` here anymore.
2019-04-12Rollup merge of #59836 - andersk:nominator, r=CentrilMazdak Farrokhzad-14/+14
std::ops::Div examples: correct nominator to numerator
2019-04-12Rollup merge of #59831 - ehuss:ordering-docs, r=kennytmMazdak Farrokhzad-3/+3
Remove strange formatting in `Ordering` docs. I can't really fathom what the intent of the brackets is. The [original PR](#12956) doesn't give any hints. I think it seems fine without them.
2019-04-12Add comment that field projectin also works with mutable fieldsChris Gregory-5/+6
2019-04-12Fix convert module's documentation linksChris Gregory-11/+11
2019-04-11Remove [mut] syntax in pin docsChris Gregory-9/+9
2019-04-11Remove note about transmute for float bitpatterns.Scott Olson-10/+0
2019-04-11Auto merge of #59211 - nox:refcell-borrow-state, r=KodrAusbors-0/+38
Introduce RefCell::try_borrow_unguarded *Come sit next to the fireplace with me, this is going to be a long story.* So, you may already be aware that Servo has weird design constraints that forces us developers working on it to do weird things. The thing that interests us today is that we do layout on a separate thread with its own thread pool to do some things in parallel, whereas the data it uses comes from the script thread, which implements the entire DOM and related pieces, with `!Sync` data types such as `RefCell<T>`. The invariant we maintain is that script does not do anything ever with the DOM data as long as layout is doing its job. That's all nice and all, but one thing we don't ensure is that we don't actually know if script was currently mutably borrowing some `RefCell<T>` prior to starting layout, which may lead to aliasing mutable memory and obviously undefined behaviour. This PR reinstates `RefCell::borrow_state` so that [this method](https://github.com/servo/servo/blob/master/components/script/dom/bindings/cell.rs#L23-L30) can make use of it and return `None` if the cell was mutably borrowed. Cc @SimonSapin
2019-04-10warn on unused results for operation methods on numsAshley Mannix-0/+156
2019-04-09std::ops::Div examples: correct nominator to numeratorAnders Kaseorg-14/+14
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-04-09Remove strange formatting in `Ordering` docs.Eric Huss-3/+3
2019-04-08Rename Waker::new_unchecked to Waker::from_rawTaylor Cramer-4/+4
2019-04-08Add Waker::wake_by_ref and make Waker::wake consume the WakerTaylor Cramer-7/+45
2019-04-08Add must_use annotations to Result::is_ok and is_errAlex Gaynor-0/+4
2019-04-07Auto merge of #59119 - cramertj:cx-back, r=withoutboatsbors-13/+108
Future-proof the Futures API cc https://github.com/rust-lang/rust/issues/59113, @carllerche, @rust-lang/libs r? @withoutboats
2019-04-06Tiny docs fixTobias Bucher-1/+1
2019-04-06Rollup merge of #59707 - GuillaumeGomez:GuillaumeGomez-patch-1, r=CentrilMazdak Farrokhzad-0/+20
Add missing tryfrom example r? @rust-lang/docs
2019-04-05Future-proof the Futures APITaylor Cramer-13/+108
2019-04-05Remove parensUnreachable-2/+2
2019-04-05Add missing tryfrom exampleGuillaume Gomez-0/+20
2019-04-05Include trailing comma in multiline Debug representationDavid Tolnay-84/+58
This commit changes the behavior of Formatter::debug_struct, debug_tuple, debug_list, debug_set, and debug_map to render trailing commas in {:#?} mode, which is the dominant style in modern Rust code. Before: Language { name: "Rust", trailing_commas: false } After: Language { name: "Rust", trailing_commas: true, }
2019-04-05improve docs for std::hint::unreachable_unchecked()Unreachable-3/+2
2019-04-04Rollup merge of #59596 - LukasKalbertodt:fix-range-fmt, r=KimundiMazdak Farrokhzad-5/+17
Forward formatter settings to bounds of `Range<T>` in `fmt::Debug` impl Before this change, formatter settings were lost when printing a `Range`. For example, printing a `Range<f32>` with `{:.2?}` would not apply the precision modifier when printing the floats. Now the `Debug` impls look a bit more verbose, but modifier are not lost. --- I assume the exact output of `Debug` impls in `std` cannot be relied on by users and thus can change, right?
2019-04-04Rollup merge of #59664 - DevQps:improve-yield-spinlock-docs, r=alexcrichtonMazdak Farrokhzad-14/+40
Updated the documentation of spin_loop and spin_loop_hint # Description - Updated the description of `core::hints::spin_loop` - Updated the description of `core::async::spin_loop_hint` Both documentation is rewritten to better reflect when one should prefer using a busy-wait spin-loop (and the `spin_loop` and `spin_loop_hint` functions) over `yield_now`. It also dives a little bit deeper on what the function actually does. closes #55418