diff options
author | Tom Tromey <tom@tromey.com> | 2018-11-19 10:52:32 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2018-11-19 11:07:07 -0700 |
commit | 994b876a510ad2ed7e0d34a4c7d08f8039cef6ef (patch) | |
tree | 6d04459a2340ae2f19f03fe5936d2ffeaf63412f /gdb/testsuite/gdb.rust | |
parent | 39a36629f68e9796d950d9204012fe8272e2d0ef (diff) | |
download | gdb-994b876a510ad2ed7e0d34a4c7d08f8039cef6ef.zip gdb-994b876a510ad2ed7e0d34a4c7d08f8039cef6ef.tar.gz gdb-994b876a510ad2ed7e0d34a4c7d08f8039cef6ef.tar.bz2 |
Fix gdb.rust/simple.rs for more recent compilers
gdb.rust/simple.exp will fail when run with a recent version of rustc.
This patch fixes the test case so that it will continue to run.
Tested on x86-64 Fedora 28.
I also temporarily backed out the rust-lang.c from
commit 098b2108a2b61531c0bc8ea16854f773083a95d7, and verified that
this updated test still would have provoked the original bug.
gdb/testsuite/ChangeLog
2018-11-19 Tom Tromey <tom@tromey.com>
* gdb.rust/simple.rs: Don't initialize empty_enum_value.
Diffstat (limited to 'gdb/testsuite/gdb.rust')
-rw-r--r-- | gdb/testsuite/gdb.rust/simple.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.rust/simple.rs b/gdb/testsuite/gdb.rust/simple.rs index 00a25e0..79d463c 100644 --- a/gdb/testsuite/gdb.rust/simple.rs +++ b/gdb/testsuite/gdb.rust/simple.rs @@ -170,7 +170,7 @@ fn main () { let u = Union { f2: 255 }; let simplelayout = SimpleLayout { f1: 8, f2: 9 }; - let empty_enum_value: EmptyEnum = unsafe { ::std::mem::zeroed() }; + let empty_enum_value: EmptyEnum; println!("{}, {}", x.0, x.1); // set breakpoint here println!("{}", diff2(92, 45)); |