Closed
Description
Passing -C debuginfo=2
to rustc
gives fewer warnings than debuginfo={0,1}
. I expected to see the same output regardless of debug symbols.
Example
% rustc src/main.rs -C debuginfo=1
warning: this expression will panic at run-time
--> src/main.rs:4:19
|
4 | let element = a[index];
| ^^^^^^^^ index out of bounds: the len is 3 but the index is 10
% rustc src/main.rs -C debuginfo=2
% rustc src/main.rs
warning: this expression will panic at run-time
--> src/main.rs:4:19
|
4 | let element = a[index];
| ^^^^^^^^ index out of bounds: the len is 3 but the index is 10
Version
% rustc --version --verbose
rustc 1.24.1 (d3ae9a9e0 2018-02-27)
binary: rustc
commit-hash: d3ae9a9e08edf12de0ed82af57ba2a56c26496ea
commit-date: 2018-02-27
host: x86_64-unknown-linux-gnu
release: 1.24.1
LLVM version: 4.0