Merge commit '0113bc9388' into sync-from-ra

This commit is contained in:
Laurențiu Nicola 2024-02-04 10:37:58 +02:00
parent f43cea0878
commit b8a3180a60
197 changed files with 3106 additions and 2007 deletions

View file

@ -15,10 +15,11 @@ doctest = false
# Avoid adding deps here, this crate is widely used in tests it should compile fast!
dissimilar = "1.0.7"
text-size.workspace = true
tracing.workspace = true
rustc-hash.workspace = true
stdx.workspace = true
profile.workspace = true
[lints]
workspace = true
workspace = true

View file

@ -28,7 +28,7 @@
//! env: option
//! eq: sized
//! error: fmt
//! fmt: result, transmute, coerce_unsized
//! fmt: option, result, transmute, coerce_unsized
//! fn:
//! from: sized
//! future: pin
@ -987,6 +987,10 @@ pub mod fmt {
Arguments { pieces, fmt: None, args }
}
pub const fn new_const(pieces: &'a [&'static str]) -> Arguments<'a> {
Arguments { pieces, fmt: None, args: &[] }
}
pub fn new_v1_formatted(
pieces: &'a [&'static str],
args: &'a [rt::Argument<'a>],
@ -1346,6 +1350,9 @@ pub mod iter {
// region:panic
mod panic {
pub macro panic_2021 {
() => (
$crate::panicking::panic("explicit panic")
),
($($t:tt)+) => (
$crate::panicking::panic_fmt($crate::const_format_args!($($t)+))
),
@ -1357,6 +1364,11 @@ mod panicking {
pub const fn panic_fmt(_fmt: crate::fmt::Arguments<'_>) -> ! {
loop {}
}
#[lang = "panic"]
pub const fn panic(expr: &'static str) -> ! {
panic_fmt(crate::fmt::Arguments::new_const(&[expr]))
}
}
// endregion:panic