Skip to content

Commit 64a6de2

Browse files
committed
Join mutiple lines if it is more readable
1 parent d4ecf31 commit 64a6de2

File tree

4 files changed

+8
-20
lines changed

4 files changed

+8
-20
lines changed

src/libcore/panic.rs

+3-6
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,7 @@ pub struct PanicInfo<'a> {
3939
impl<'a> PanicInfo<'a> {
4040
#[unstable(
4141
feature = "panic_internals",
42-
reason = "internal details of the implementation of the `panic!` \
43-
and related macros",
42+
reason = "internal details of the implementation of the `panic!` and related macros",
4443
issue = "none"
4544
)]
4645
#[doc(hidden)]
@@ -55,8 +54,7 @@ impl<'a> PanicInfo<'a> {
5554

5655
#[unstable(
5756
feature = "panic_internals",
58-
reason = "internal details of the implementation of the `panic!` \
59-
and related macros",
57+
reason = "internal details of the implementation of the `panic!` and related macros",
6058
issue = "none"
6159
)]
6260
#[doc(hidden)]
@@ -244,8 +242,7 @@ impl<'a> Location<'a> {
244242
impl<'a> Location<'a> {
245243
#![unstable(
246244
feature = "panic_internals",
247-
reason = "internal details of the implementation of the `panic!` \
248-
and related macros",
245+
reason = "internal details of the implementation of the `panic!` and related macros",
249246
issue = "none"
250247
)]
251248
#[doc(hidden)]

src/libcore/panicking.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@
2222
#![allow(dead_code, missing_docs)]
2323
#![unstable(
2424
feature = "core_panic",
25-
reason = "internal details of the implementation of the `panic!` \
26-
and related macros",
25+
reason = "internal details of the implementation of the `panic!` and related macros",
2726
issue = "none"
2827
)]
2928

src/librustc_middle/ty/context.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -189,8 +189,7 @@ fn validate_hir_id_for_typeck_tables(
189189
if hir_id.owner != hir_owner {
190190
ty::tls::with(|tcx| {
191191
bug!(
192-
"node {} with HirId::owner {:?} cannot be placed in \
193-
TypeckTables with hir_owner {:?}",
192+
"node {} with HirId::owner {:?} cannot be placed in TypeckTables with hir_owner {:?}",
194193
tcx.hir().node_to_string(hir_id),
195194
hir_id.owner,
196195
hir_owner

src/libstd/panicking.rs

+3-10
Original file line numberDiff line numberDiff line change
@@ -201,8 +201,7 @@ fn default_hook(info: &PanicInfo<'_>) {
201201
if FIRST_PANIC.swap(false, Ordering::SeqCst) {
202202
let _ = writeln!(
203203
err,
204-
"note: run with `RUST_BACKTRACE=1` \
205-
environment variable to display a backtrace"
204+
"note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace"
206205
);
207206
}
208207
}
@@ -454,10 +453,7 @@ fn rust_panic_with_hook(
454453
// process real quickly as we don't want to try calling it again as it'll
455454
// probably just panic again.
456455
if panics > 2 {
457-
util::dumb_print(format_args!(
458-
"thread panicked while processing \
459-
panic. aborting.\n"
460-
));
456+
util::dumb_print(format_args!("thread panicked while processing panic. aborting.\n"));
461457
intrinsics::abort()
462458
}
463459

@@ -489,10 +485,7 @@ fn rust_panic_with_hook(
489485
// have limited options. Currently our preference is to
490486
// just abort. In the future we may consider resuming
491487
// unwinding or otherwise exiting the thread cleanly.
492-
util::dumb_print(format_args!(
493-
"thread panicked while panicking. \
494-
aborting.\n"
495-
));
488+
util::dumb_print(format_args!("thread panicked while panicking. aborting.\n"));
496489
intrinsics::abort()
497490
}
498491

0 commit comments

Comments
 (0)