Skip to content

Rollup of 15 pull requests #77198

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 38 commits into from
Sep 25, 2020
Merged
Changes from 2 commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
26d6081
Relax promises about condition variable.
m-ou-se Sep 19, 2020
3e08354
Correct file path after some restructures in compiler
tesuji Sep 20, 2020
4387480
Add unstably const support for assume intrinsic
tesuji Sep 20, 2020
4b6a482
Fix dest prop miscompilation around references
jonas-schievink Sep 22, 2020
928a29f
Bless mir-opt tests
jonas-schievink Sep 22, 2020
438d229
dead_code: look at trait impls even if they don't contain items
lcnr Sep 22, 2020
9f27f37
Include libunwind in the rust-src component.
ehuss Sep 23, 2020
631c688
Make [].as_[mut_]ptr_range() (unstably) const.
m-ou-se Sep 23, 2020
b5d47bf
clarify that `changelog-seen = 1` goes to the beginning of config.toml
matthiaskrgr Sep 23, 2020
bcbd2cc
Add `keep-stage-std` to `x.py`
ecstatic-morse Sep 23, 2020
df004df
Re-download LLVM on submodule updates only
Mark-Simulacrum Sep 23, 2020
ef95430
Adjust support expectations for downloaded LLVMs
Mark-Simulacrum Sep 23, 2020
c0ddaed
Remove warning about possible future deprecation
ecstatic-morse Sep 23, 2020
16769eb
Add entry to CHANGELOG for `--keep-stage-std`
ecstatic-morse Sep 23, 2020
4de836e
Install std for non-host targets
Mark-Simulacrum Sep 24, 2020
382d724
move test to intergrated test in library/core
tesuji Sep 24, 2020
1857184
remove enum name from ImplSource variants
lcnr Sep 24, 2020
1d3717d
Removing erroneous semicolon
austinkeeley Sep 25, 2020
1e64d98
BTreeMap: refactor correct_childrens_parent_links
ssomers Aug 9, 2020
3965524
BTreeMap: introduce edge methods similar to those of keys and values
ssomers Aug 9, 2020
55fa8af
BTreeMap: various tweaks
ssomers Aug 9, 2020
54c9c94
Allow multiple allow_internal_unstable attributes
bugadani Sep 25, 2020
606ed2a
Remove extra space from vec drawing
pickfire Sep 25, 2020
a835af1
Rollup merge of #76932 - fusion-engineering-forks:condvar-promise, r=…
jonas-schievink Sep 25, 2020
1b8c939
Rollup merge of #76973 - lzutao:unstably-const-assume, r=oli-obk
jonas-schievink Sep 25, 2020
e8dc07c
Rollup merge of #77005 - ssomers:btree_cleanup_3, r=Mark-Simulacrum
jonas-schievink Sep 25, 2020
452aa75
Rollup merge of #77066 - jonas-schievink:dest-prop-borrow, r=oli-obk
jonas-schievink Sep 25, 2020
ba44e9f
Rollup merge of #77073 - lcnr:ty-trait-param, r=matthewjasper
jonas-schievink Sep 25, 2020
b49990c
Rollup merge of #77086 - ehuss:src-libunwind, r=Mark-Simulacrum
jonas-schievink Sep 25, 2020
1149b30
Rollup merge of #77097 - fusion-engineering-forks:slice-ptr-range-con…
jonas-schievink Sep 25, 2020
8621ef1
Rollup merge of #77106 - matthiaskrgr:changelog_seen, r=Mark-Simulacrum
jonas-schievink Sep 25, 2020
0a3cf02
Rollup merge of #77120 - ecstatic-morse:keep-stage-std, r=Mark-Simula…
jonas-schievink Sep 25, 2020
61dc57c
Rollup merge of #77126 - Mark-Simulacrum:llvm-less-often, r=alexcrichton
jonas-schievink Sep 25, 2020
ba3e25f
Rollup merge of #77146 - Mark-Simulacrum:xpyinstall, r=alexcrichton
jonas-schievink Sep 25, 2020
e739468
Rollup merge of #77155 - lcnr:ImplSource, r=ecstatic-morse
jonas-schievink Sep 25, 2020
a7bdf85
Rollup merge of #77176 - austinkeeley:intrinsics-documentatation-erro…
jonas-schievink Sep 25, 2020
12b8d89
Rollup merge of #77183 - bugadani:issue-77088, r=varkor
jonas-schievink Sep 25, 2020
d72b7cc
Rollup merge of #77189 - pickfire:patch-5, r=Mark-Simulacrum
jonas-schievink Sep 25, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions library/core/src/slice/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -433,8 +433,9 @@ impl<T> [T] {
/// assert_eq!(x, &[3, 4, 6]);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
#[rustc_const_unstable(feature = "const_ptr_offset", issue = "71499")]
#[inline]
pub fn as_mut_ptr(&mut self) -> *mut T {
pub const fn as_mut_ptr(&mut self) -> *mut T {
self as *mut [T] as *mut T
}

Expand Down Expand Up @@ -469,8 +470,9 @@ impl<T> [T] {
///
/// [`as_ptr`]: #method.as_ptr
#[unstable(feature = "slice_ptr_range", issue = "65807")]
#[rustc_const_unstable(feature = "const_ptr_offset", issue = "71499")]
#[inline]
pub fn as_ptr_range(&self) -> Range<*const T> {
pub const fn as_ptr_range(&self) -> Range<*const T> {
let start = self.as_ptr();
// SAFETY: The `add` here is safe, because:
//
Expand Down Expand Up @@ -510,8 +512,9 @@ impl<T> [T] {
///
/// [`as_mut_ptr`]: #method.as_mut_ptr
#[unstable(feature = "slice_ptr_range", issue = "65807")]
#[rustc_const_unstable(feature = "const_ptr_offset", issue = "71499")]
#[inline]
pub fn as_mut_ptr_range(&mut self) -> Range<*mut T> {
pub const fn as_mut_ptr_range(&mut self) -> Range<*mut T> {
let start = self.as_mut_ptr();
// SAFETY: See as_ptr_range() above for why `add` here is safe.
let end = unsafe { start.add(self.len()) };
Expand Down