about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEduard-Mihai Burtescu <edy.burt@gmail.com>2017-05-10 14:37:29 +0300
committerEduard-Mihai Burtescu <edy.burt@gmail.com>2017-05-10 14:37:29 +0300
commitd23a65077add9da538e7ba2c2d3c3baae7a8597e (patch)
treeb67a062258fdb00dddb6902a1b74d5037f4779c9
parent58b33ad70cdd11f9ce7b5874c6effab9627e51aa (diff)
downloadrust-d23a65077add9da538e7ba2c2d3c3baae7a8597e.tar.gz
rust-d23a65077add9da538e7ba2c2d3c3baae7a8597e.zip
compiletest: force GDB to print values in the Rust format.
-rw-r--r--src/tools/compiletest/src/runtest.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs
index a044282666d..461cb59bf7d 100644
--- a/src/tools/compiletest/src/runtest.rs
+++ b/src/tools/compiletest/src/runtest.rs
@@ -647,6 +647,11 @@ actual:\n\
                                              exe_file.to_str().unwrap()
                                              .replace(r"\", r"\\")));
 
+                // Force GDB to print values in the Rust format.
+                if self.config.gdb_native_rust {
+                    script_str.push_str("set language rust\n");
+                }
+
                 // Add line breakpoints
                 for line in &breakpoint_lines {
                     script_str.push_str(&format!("break '{}':{}\n",