aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorJoel Brobecker <brobecker@gnat.com>2011-11-23 19:21:12 +0000
committerJoel Brobecker <brobecker@gnat.com>2011-11-23 19:21:12 +0000
commit18af828477ee67ca2aafdec98d16107a2d792d66 (patch)
tree0b624ad1db374a5b3874a58a9f2e7bd915dd294d /gdb
parent1fc7b5d7252fd6607520c043dd65981c750566c6 (diff)
downloadgdb-18af828477ee67ca2aafdec98d16107a2d792d66.zip
gdb-18af828477ee67ca2aafdec98d16107a2d792d66.tar.gz
gdb-18af828477ee67ca2aafdec98d16107a2d792d66.tar.bz2
ada-lang.c: Rename function base_type into get_base_type
This avoids shadowing issues with variables named base_type. gdb/ChangeLog: * ada-lang.c (get_base_type): Renames base_type. Adjust all calls throughout this file.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/ada-lang.c14
2 files changed, 12 insertions, 7 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index e16f120..3bb6d51 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,10 @@
2011-11-23 Joel Brobecker <brobecker@adacore.com>
+ * ada-lang.c (get_base_type): Renames base_type. Adjust all
+ calls throughout this file.
+
+2011-11-23 Joel Brobecker <brobecker@adacore.com>
+
* gdb-dlfcn.c (gdb_dlopen): Add missing coma in call to
FormatMessage.
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index 2edbe7f..6676685 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -716,7 +716,7 @@ ada_discrete_type_low_bound (struct type *type)
non-range scalar type. */
static struct type *
-base_type (struct type *type)
+get_base_type (struct type *type)
{
while (type != NULL && TYPE_CODE (type) == TYPE_CODE_RANGE)
{
@@ -3325,13 +3325,13 @@ return_match (struct type *func_type, struct type *context_type)
return 1;
if (TYPE_CODE (func_type) == TYPE_CODE_FUNC)
- return_type = base_type (TYPE_TARGET_TYPE (func_type));
+ return_type = get_base_type (TYPE_TARGET_TYPE (func_type));
else
- return_type = base_type (func_type);
+ return_type = get_base_type (func_type);
if (return_type == NULL)
return 1;
- context_type = base_type (context_type);
+ context_type = get_base_type (context_type);
if (TYPE_CODE (return_type) == TYPE_CODE_ENUM)
return context_type == NULL || return_type == context_type;
@@ -8500,8 +8500,8 @@ ada_value_binop (struct value *arg1, struct value *arg2, enum exp_opcode op)
arg1 = coerce_ref (arg1);
arg2 = coerce_ref (arg2);
- type1 = base_type (ada_check_typedef (value_type (arg1)));
- type2 = base_type (ada_check_typedef (value_type (arg2)));
+ type1 = get_base_type (ada_check_typedef (value_type (arg1)));
+ type2 = get_base_type (ada_check_typedef (value_type (arg2)));
if (TYPE_CODE (type1) != TYPE_CODE_INT
|| TYPE_CODE (type2) != TYPE_CODE_INT)
@@ -10453,7 +10453,7 @@ ada_is_range_type_name (const char *name)
int
ada_is_modular_type (struct type *type)
{
- struct type *subranged_type = base_type (type);
+ struct type *subranged_type = get_base_type (type);
return (subranged_type != NULL && TYPE_CODE (type) == TYPE_CODE_RANGE
&& TYPE_CODE (subranged_type) == TYPE_CODE_INT