Skip to content

Commit

Permalink
Undo format changes
Browse files Browse the repository at this point in the history
  • Loading branch information
celinval committed Oct 16, 2024
1 parent 18b61ff commit fbc8c69
Showing 1 changed file with 5 additions and 18 deletions.
23 changes: 5 additions & 18 deletions library/core/src/intrinsics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,8 @@
)]
#![allow(missing_docs)]

use crate::marker::DiscriminantKind;
use crate::marker::Tuple;
use crate::ptr;
use crate::ub_checks;
use crate::marker::{DiscriminantKind, Tuple};
use crate::{ptr, ub_checks};
use safety::{ensures, requires};

#[cfg(kani)]
Expand All @@ -77,19 +75,12 @@ pub mod simd;

// These imports are used for simplifying intra-doc links
#[allow(unused_imports)]
#[cfg(all(
target_has_atomic = "8",
target_has_atomic = "32",
target_has_atomic = "ptr"
))]
#[cfg(all(target_has_atomic = "8", target_has_atomic = "32", target_has_atomic = "ptr"))]
use crate::sync::atomic::{self, AtomicBool, AtomicI32, AtomicIsize, AtomicU32, Ordering};

#[stable(feature = "drop_in_place", since = "1.8.0")]
#[rustc_allowed_through_unstable_modules]
#[deprecated(
note = "no longer an intrinsic - use `ptr::drop_in_place` directly",
since = "1.52.0"
)]
#[deprecated(note = "no longer an intrinsic - use `ptr::drop_in_place` directly", since = "1.52.0")]
#[inline]
pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
// SAFETY: see `ptr::drop_in_place`
Expand Down Expand Up @@ -1039,11 +1030,7 @@ pub const fn unlikely(b: bool) -> bool {
#[miri::intrinsic_fallback_is_spec]
#[inline]
pub fn select_unpredictable<T>(b: bool, true_val: T, false_val: T) -> T {
if b {
true_val
} else {
false_val
}
if b { true_val } else { false_val }
}

extern "rust-intrinsic" {
Expand Down

0 comments on commit fbc8c69

Please sign in to comment.