X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=gdb%2Fvalprint.c;h=2b995da9745c8b248e39908194a48dc1b1a57317;hb=7678ef8fb055dd4853c7c6b25f739a8d74650899;hp=eb3a73b4ef3ccff5025feda89cf266aa9d4a61c9;hpb=9b913628cfe092b3fdd328de4264def1ec1e94cb;p=binutils-gdb.git diff --git a/gdb/valprint.c b/gdb/valprint.c index eb3a73b4ef3..2b995da9745 100644 --- a/gdb/valprint.c +++ b/gdb/valprint.c @@ -33,6 +33,7 @@ #include "floatformat.h" #include "doublest.h" #include "exceptions.h" +#include "dfp.h" #include @@ -505,6 +506,18 @@ print_floating (const gdb_byte *valaddr, struct type *type, #endif } +void +print_decimal_floating (const gdb_byte *valaddr, struct type *type, + struct ui_file *stream) +{ + char decstr[MAX_DECIMAL_STRING]; + unsigned len = TYPE_LENGTH (type); + + decimal_to_string (valaddr, len, decstr); + fputs_filtered (decstr, stream); + return; +} + void print_binary_chars (struct ui_file *stream, const gdb_byte *valaddr, unsigned len)