Skip to content

Commit e11a9fa

Browse files
committedApr 24, 2021
Auto merge of rust-lang#84501 - JohnTitor:rollup-wxu1thu, r=JohnTitor
Rollup of 10 pull requests Successful merges: - rust-lang#83990 (implement `TrustedRandomAccess` for `Take` iterator adapter) - rust-lang#84250 (bootstrap: use bash on illumos to run install scripts) - rust-lang#84320 (Use details tag for trait implementors.) - rust-lang#84436 (Make a few functions private) - rust-lang#84453 (Document From implementations for Waker and RawWaker) - rust-lang#84458 (Remove unnecessary fields and parameters in rustdoc) - rust-lang#84485 (Add some associated type bounds tests) - rust-lang#84489 (Mention FusedIterator case in Iterator::fuse doc) - rust-lang#84492 (rustdoc: Remove unnecessary dummy span) - rust-lang#84496 (Add some specialization tests) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2 parents a7aba58 + ec61abf commit e11a9fa

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+324
-152
lines changed
 

‎compiler/rustc_session/src/config.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,7 @@ pub const fn default_lib_output() -> CrateType {
797797
CrateType::Rlib
798798
}
799799

800-
pub fn default_configuration(sess: &Session) -> CrateConfig {
800+
fn default_configuration(sess: &Session) -> CrateConfig {
801801
let end = &sess.target.endian;
802802
let arch = &sess.target.arch;
803803
let wordsz = sess.target.pointer_width.to_string();
@@ -892,7 +892,7 @@ pub fn build_configuration(sess: &Session, mut user_cfg: CrateConfig) -> CrateCo
892892
user_cfg
893893
}
894894

895-
pub fn build_target_config(opts: &Options, target_override: Option<Target>) -> Target {
895+
pub(super) fn build_target_config(opts: &Options, target_override: Option<Target>) -> Target {
896896
let target_result = target_override.map_or_else(|| Target::search(&opts.target_triple), Ok);
897897
let target = target_result.unwrap_or_else(|e| {
898898
early_error(

‎library/alloc/src/task.rs

+6
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@ pub trait Wake {
8787

8888
#[stable(feature = "wake_trait", since = "1.51.0")]
8989
impl<W: Wake + Send + Sync + 'static> From<Arc<W>> for Waker {
90+
/// Use a `Wake`-able type as a `Waker`.
91+
///
92+
/// No heap allocations or atomic operations are used for this conversion.
9093
fn from(waker: Arc<W>) -> Waker {
9194
// SAFETY: This is safe because raw_waker safely constructs
9295
// a RawWaker from Arc<W>.
@@ -96,6 +99,9 @@ impl<W: Wake + Send + Sync + 'static> From<Arc<W>> for Waker {
9699

97100
#[stable(feature = "wake_trait", since = "1.51.0")]
98101
impl<W: Wake + Send + Sync + 'static> From<Arc<W>> for RawWaker {
102+
/// Use a `Wake`-able type as a `RawWaker`.
103+
///
104+
/// No heap allocations or atomic operations are used for this conversion.
99105
fn from(waker: Arc<W>) -> RawWaker {
100106
raw_waker(waker)
101107
}

0 commit comments

Comments
 (0)
Please sign in to comment.