Skip to content

Commit 7b29f90

Browse files
authored
Rollup merge of rust-lang#41877 - eddyb:gdb-force-rust, r=michaelwoerister
compiletest: force GDB to print values in the Rust format. Based on @nodakai's rust-lang#40557 (comment) and @infinity0's rust-lang#40557 (comment). Fixes rust-lang#40557.
2 parents 7e38b09 + d23a650 commit 7b29f90

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/tools/compiletest/src/runtest.rs

+5
Original file line numberDiff line numberDiff line change
@@ -647,6 +647,11 @@ actual:\n\
647647
exe_file.to_str().unwrap()
648648
.replace(r"\", r"\\")));
649649

650+
// Force GDB to print values in the Rust format.
651+
if self.config.gdb_native_rust {
652+
script_str.push_str("set language rust\n");
653+
}
654+
650655
// Add line breakpoints
651656
for line in &breakpoint_lines {
652657
script_str.push_str(&format!("break '{}':{}\n",

0 commit comments

Comments
 (0)