From 57e5f9384a746fb3a39184c28f6e86b15e6b4aa7 Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Sun, 21 Sep 2003 19:11:47 +0000 Subject: gdb 2003-09-19 Daniel Jacobowitz Merge from mainline: 2003-09-15 Daniel Jacobowitz * values.c (unpack_double): Call floatformat_is_valid. include 2003-09-15 Andrew Cagney * floatformat.h (floatformat_to_double): Make input buffer constant. (floatformat_from_double, floatformat_is_valid): Ditto. 2003-09-15 Daniel Jacobowitz * floatformat.h (floatformat_is_valid): Add prototype. libiberty 2003-09-15 Andrew Cagney * floatformat.c (get_field): Make "data" constant. (floatformat_is_valid, floatformat_to_double): Make "from" constant, fix casts. (floatformat_from_double): Make "from" constant. 2003-09-15 Daniel Jacobowitz * floatformat.c (floatformat_is_valid): New function. (get_field, put_field): Correct comments. --- include/ChangeLog | 9 +++++++++ include/floatformat.h | 11 ++++++++--- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/include/ChangeLog b/include/ChangeLog index 5e9ac7a..cecf35c 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,12 @@ +2003-09-15 Andrew Cagney + + * floatformat.h (floatformat_to_double): Make input buffer constant. + (floatformat_from_double, floatformat_is_valid): Ditto. + +2003-09-15 Daniel Jacobowitz + + * floatformat.h (floatformat_is_valid): Add prototype. + 2003-06-22 Zack Weinberg * safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC): Rename to diff --git a/include/floatformat.h b/include/floatformat.h index 53ead3e..c92ab93 100644 --- a/include/floatformat.h +++ b/include/floatformat.h @@ -1,5 +1,5 @@ /* IEEE floating point support declarations, for GDB, the GNU Debugger. - Copyright 1991, 1994, 1995, 1997, 2000 Free Software Foundation, Inc. + Copyright 1991, 1994, 1995, 1997, 2000, 2003 Free Software Foundation, Inc. This file is part of GDB. @@ -109,13 +109,18 @@ extern const struct floatformat floatformat_ia64_quad_little; Store the double in *TO. */ extern void -floatformat_to_double PARAMS ((const struct floatformat *, char *, double *)); +floatformat_to_double PARAMS ((const struct floatformat *, const char *, double *)); /* The converse: convert the double *FROM to FMT and store where TO points. */ extern void floatformat_from_double PARAMS ((const struct floatformat *, - double *, char *)); + const double *, char *)); + +/* Return non-zero iff the data at FROM is a valid number in format FMT. */ + +extern int +floatformat_is_valid PARAMS ((const struct floatformat *fmt, const char *from)); #endif /* defined (FLOATFORMAT_H) */ -- cgit v1.1