]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/rust-lang.c
Implement value_print for Rust
authorTom Tromey <tom@tromey.com>
Sun, 27 Mar 2022 21:29:28 +0000 (15:29 -0600)
committerTom Tromey <tom@tromey.com>
Fri, 15 Apr 2022 16:34:03 +0000 (10:34 -0600)
commit1c9cc05244f67c4e5a888394b2c9a309164ca02d
tree4793ceaf045ebb1302482a69c75e0e913275bd45
parent506ec52e8805d8edd538d6bd11750489a8c8bbee
Implement value_print for Rust

This adds an implementation of the value_print method to Rust.  As
described in PR rust/22254, this removes a bit of weird-looking output
from some "print"s -- because c_value_print is bypassed.  I don't have
a test for the bug that inspired this patch, because I only know how
to reproduce it when using a relatively old Rust compiler.  However,
the new "cast-printing" code in value_print is required, because
omitting this causes some existing tests to fail.

Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=22254
gdb/rust-lang.c
gdb/rust-lang.h