Skip to content

Commit 2d66e5a

Browse files
committed
Auto merge of #111835 - matthiaskrgr:rollup-qd4b2vu, r=matthiaskrgr
Rollup of 2 pull requests Successful merges: - #111810 (Don't use inner macro in `marker_impls`) - #111826 (Render test messages from bootstrap) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 7ca94f2 + e2362d7 commit 2d66e5a

File tree

2 files changed

+15
-20
lines changed

2 files changed

+15
-20
lines changed

library/core/src/marker.rs

+8-18
Original file line numberDiff line numberDiff line change
@@ -43,27 +43,17 @@ use crate::hash::Hasher;
4343
/// ```
4444
#[unstable(feature = "internal_impls_macro", issue = "none")]
4545
macro marker_impls {
46-
( $(#[$($meta:tt)*])* $Trait:ident for $( $({$($bounds:tt)*})? $T:ty ),+ $(,)?) => {
47-
// This inner macro is needed because... idk macros are weird.
48-
// It allows repeating `meta` on all impls.
49-
#[unstable(feature = "internal_impls_macro", issue = "none")]
50-
macro _impl {
51-
( $$({$$($$bounds_:tt)*})? $$T_:ty ) => {
52-
$(#[$($meta)*])* impl<$$($$($$bounds_)*)?> $Trait for $$T_ {}
53-
}
54-
}
55-
$( _impl! { $({$($bounds)*})? $T } )+
46+
( $(#[$($meta:tt)*])* $Trait:ident for $({$($bounds:tt)*})? $T:ty $(, $($rest:tt)*)? ) => {
47+
$(#[$($meta)*])* impl< $($($bounds)*)? > $Trait for $T {}
48+
marker_impls! { $(#[$($meta)*])* $Trait for $($($rest)*)? }
5649
},
57-
( $(#[$($meta:tt)*])* unsafe $Trait:ident for $( $({$($bounds:tt)*})? $T:ty ),+ $(,)?) => {
58-
#[unstable(feature = "internal_impls_macro", issue = "none")]
59-
macro _impl {
60-
( $$({$$($$bounds_:tt)*})? $$T_:ty ) => {
61-
$(#[$($meta)*])* unsafe impl<$$($$($$bounds_)*)?> $Trait for $$T_ {}
62-
}
63-
}
50+
( $(#[$($meta:tt)*])* $Trait:ident for ) => {},
6451

65-
$( _impl! { $({$($bounds)*})? $T } )+
52+
( $(#[$($meta:tt)*])* unsafe $Trait:ident for $({$($bounds:tt)*})? $T:ty $(, $($rest:tt)*)? ) => {
53+
$(#[$($meta)*])* unsafe impl< $($($bounds)*)? > $Trait for $T {}
54+
marker_impls! { $(#[$($meta)*])* unsafe $Trait for $($($rest)*)? }
6655
},
56+
( $(#[$($meta:tt)*])* unsafe $Trait:ident for ) => {},
6757
}
6858

6959
/// Types that can be transferred across thread boundaries.

src/bootstrap/render_tests.rs

+7-2
Original file line numberDiff line numberDiff line change
@@ -168,9 +168,14 @@ impl<'a> Renderer<'a> {
168168
if !self.failures.is_empty() {
169169
println!("\nfailures:\n");
170170
for failure in &self.failures {
171-
if let Some(stdout) = &failure.stdout {
171+
if failure.stdout.is_some() || failure.message.is_some() {
172172
println!("---- {} stdout ----", failure.name);
173-
println!("{stdout}");
173+
if let Some(stdout) = &failure.stdout {
174+
println!("{stdout}");
175+
}
176+
if let Some(message) = &failure.message {
177+
println!("note: {message}");
178+
}
174179
}
175180
}
176181

0 commit comments

Comments
 (0)