about summary refs log tree commit diff
path: root/compiler/rustc_codegen_gcc
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-08-01 14:15:09 +0000
committerbors <bors@rust-lang.org>2023-08-01 14:15:09 +0000
commit828bdc2c26f5c95773c4ecf72870919f16417b66 (patch)
tree6e697963b24ec229b1cec777d9b1286864afb5d5 /compiler/rustc_codegen_gcc
parentc435af0d5c47a333c7cb7f359f3586d5c9dab3ab (diff)
parent2c5ecf22a2aaaecf0bfc9f3f94259913a1d00c74 (diff)
downloadrust-828bdc2c26f5c95773c4ecf72870919f16417b66.tar.gz
rust-828bdc2c26f5c95773c4ecf72870919f16417b66.zip
Auto merge of #112849 - m-ou-se:panic-message-format, r=thomcc
Change default panic handler message format.

This changes the default panic hook's message format from:

```
thread '{thread}' panicked at '{message}', {location}
```

to

```
thread '{thread}' panicked at {location}:
{message}
```

This puts the message on its own line without surrounding quotes, making it easiser to read. For example:

Before:
```
thread 'main' panicked at 'env variable `IMPORTANT_PATH` should be set by `wrapper_script.sh`', src/main.rs:4:6
```
After:
```
thread 'main' panicked at src/main.rs:4:6:
env variable `IMPORTANT_PATH` should be set by `wrapper_script.sh`
```

---

See this PR by `@nyurik,` which does that for only multi-line messages (specifically because of `assert_eq`): https://github.com/rust-lang/rust/pull/111071

This is the change that does that for *all* panic messages.
Diffstat (limited to 'compiler/rustc_codegen_gcc')
0 files changed, 0 insertions, 0 deletions