aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorPeter Schauer <Peter.Schauer@mytum.de>1998-05-23 09:31:41 +0000
committerPeter Schauer <Peter.Schauer@mytum.de>1998-05-23 09:31:41 +0000
commitbe5f18e14031b39d0e15f3b284b56a7b8a4a9e59 (patch)
tree0d31301959af7f130b01d47d974fc9facf8a991f /gdb
parentcbc6c9b2bf1ccf602b17c44776a23915419a890a (diff)
downloadgdb-be5f18e14031b39d0e15f3b284b56a7b8a4a9e59.zip
gdb-be5f18e14031b39d0e15f3b284b56a7b8a4a9e59.tar.gz
gdb-be5f18e14031b39d0e15f3b284b56a7b8a4a9e59.tar.bz2
* dwarf2read.c (read_subroutine_type): Set TYPE_FLAG_PROTOTYPED
on C++ functions. * valops.c (value_arg_coerce): Add new argument to indicate whether the function has a prototype, handle integer and float promotions accordingly. (call_function_by_hand): Always call value_arg_coerce, pass down prototype information.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog10
-rw-r--r--gdb/dwarf2read.c7
2 files changed, 15 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 1dd926f..0b7ed73 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,13 @@
+Sat May 23 02:23:09 1998 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
+
+ * dwarf2read.c (read_subroutine_type): Set TYPE_FLAG_PROTOTYPED
+ on C++ functions.
+ * valops.c (value_arg_coerce): Add new argument to indicate whether
+ the function has a prototype, handle integer and float promotions
+ accordingly.
+ (call_function_by_hand): Always call value_arg_coerce, pass down
+ prototype information.
+
Fri May 22 10:56:36 1998 John Metzler <jmetzler@cygnus.com>
* remote.c (_initialize_remote): Typo extended__remote
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
index b6162d4..2987882 100644
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -1,5 +1,5 @@
/* DWARF 2 debugging format support for GDB.
- Copyright 1994, 1995, 1996, 1997 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Adapted by Gary Funck (gary@intrepid.com), Intrepid Technology,
Inc. with support from Florida State University (under contract
@@ -2801,8 +2801,11 @@ read_subroutine_type (die, objfile)
}
type = die_type (die, objfile);
ftype = lookup_function_type (type);
+
+ /* All functions in C++ have prototypes. */
attr = dwarf_attr (die, DW_AT_prototyped);
- if (attr && (DW_UNSND (attr) != 0))
+ if ((attr && (DW_UNSND (attr) != 0))
+ || cu_language == language_cplus)
TYPE_FLAGS (ftype) |= TYPE_FLAG_PROTOTYPED;
if (die->has_children)