Skip to content

Commit f473aee

Browse files
committed
gdb < RUST_BACKTRACE
Fixes #19717
1 parent c38e73f commit f473aee

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

src/doc/complement-bugreport.md

+8-3
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ It's also helpful to provide the exact version and host by copying the output of
3737
re-running the erroneous rustc command with the `--version=verbose` flag, which will
3838
produce something like this:
3939

40-
```{ignore}
40+
```text
4141
rustc 0.12.0 (ba4081a5a 2014-10-07 13:44:41 -0700)
4242
binary: rustc
4343
commit-hash: ba4081a5a8573875fed17545846f6f6902c8ba8d
@@ -46,8 +46,13 @@ host: i686-apple-darwin
4646
release: 0.12.0
4747
```
4848

49-
Finally, if you can run the offending command under gdb, pasting a stack trace can be
50-
useful; to do so, you will need to set a breakpoint on `rust_panic`.
49+
Finally, if you can also provide a backtrace, that'd be great. You can get a
50+
backtrace by setting the `RUST_BACKTRACE` environment variable to `1`, like
51+
this:
52+
53+
```bash
54+
$ RUST_BACKTRACE=1 rustc ...
55+
```
5156

5257
# I submitted a bug, but nobody has commented on it!
5358

0 commit comments

Comments
 (0)