This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 11/18] poison "template"


From: Tom Tromey <tromey@redhat.com>

gdb/ChangeLog

2013-10-21  Tom Tromey  <tromey@redhat.com>

	* ada-lang.c (templ): Renamed from template.
	* ia64-tdep.c (templ): Likewise.
---
 gdb/ada-lang.c  |  4 ++--
 gdb/ia64-tdep.c | 30 +++++++++++++++---------------
 2 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index 69e2d2b..bf50d72 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -7553,9 +7553,9 @@ variant_field_index (struct type *type)
 /* A record type with no fields.  */
 
 static struct type *
-empty_record (struct type *template)
+empty_record (struct type *templ)
 {
-  struct type *type = alloc_type_copy (template);
+  struct type *type = alloc_type_copy (templ);
 
   TYPE_CODE (type) = TYPE_CODE_STRUCT;
   TYPE_NFIELDS (type) = 0;
diff --git a/gdb/ia64-tdep.c b/gdb/ia64-tdep.c
index 44000b9..8efed4a 100644
--- a/gdb/ia64-tdep.c
+++ b/gdb/ia64-tdep.c
@@ -513,7 +513,7 @@ fetch_instruction (CORE_ADDR addr, instruction_type *it, long long *instr)
 {
   gdb_byte bundle[BUNDLE_LEN];
   int slotnum = (int) (addr & 0x0f) / SLOT_MULTIPLIER;
-  long long template;
+  long long templ;
   int val;
 
   /* Warn about slot numbers greater than 2.  We used to generate
@@ -544,8 +544,8 @@ fetch_instruction (CORE_ADDR addr, instruction_type *it, long long *instr)
     return 0;
 
   *instr = slotN_contents (bundle, slotnum);
-  template = extract_bit_field (bundle, 0, 5);
-  *it = template_encoding_table[(int)template][slotnum];
+  templ = extract_bit_field (bundle, 0, 5);
+  *it = template_encoding_table[(int)templ][slotnum];
 
   if (slotnum == 2 || (slotnum == 1 && *it == L))
     addr += 16;
@@ -643,7 +643,7 @@ ia64_memory_insert_breakpoint (struct gdbarch *gdbarch,
   int slotnum = (int) (addr & 0x0f) / SLOT_MULTIPLIER, shadow_slotnum;
   long long instr_breakpoint;
   int val;
-  int template;
+  int templ;
   struct cleanup *cleanup;
 
   if (slotnum > 2)
@@ -672,8 +672,8 @@ ia64_memory_insert_breakpoint (struct gdbarch *gdbarch,
      a breakpoint on an L-X instruction.  */
   bp_tgt->shadow_len = BUNDLE_LEN - shadow_slotnum;
 
-  template = extract_bit_field (bundle, 0, 5);
-  if (template_encoding_table[template][slotnum] == X)
+  templ = extract_bit_field (bundle, 0, 5);
+  if (template_encoding_table[templ][slotnum] == X)
     {
       /* X unit types can only be used in slot 2, and are actually
 	 part of a 2-slot L-X instruction.  We cannot break at this
@@ -682,7 +682,7 @@ ia64_memory_insert_breakpoint (struct gdbarch *gdbarch,
       gdb_assert (slotnum == 2);
       error (_("Can't insert breakpoint for non-existing slot X"));
     }
-  if (template_encoding_table[template][slotnum] == L)
+  if (template_encoding_table[templ][slotnum] == L)
     {
       /* L unit types can only be used in slot 1.  But the associated
 	 opcode for that instruction is in slot 2, so bump the slot number
@@ -740,7 +740,7 @@ ia64_memory_remove_breakpoint (struct gdbarch *gdbarch,
   int slotnum = (addr & 0x0f) / SLOT_MULTIPLIER, shadow_slotnum;
   long long instr_breakpoint, instr_saved;
   int val;
-  int template;
+  int templ;
   struct cleanup *cleanup;
 
   addr &= ~0x0f;
@@ -762,8 +762,8 @@ ia64_memory_remove_breakpoint (struct gdbarch *gdbarch,
      for addressing the SHADOW_CONTENTS placement.  */
   shadow_slotnum = slotnum;
 
-  template = extract_bit_field (bundle_mem, 0, 5);
-  if (template_encoding_table[template][slotnum] == X)
+  templ = extract_bit_field (bundle_mem, 0, 5);
+  if (template_encoding_table[templ][slotnum] == X)
     {
       /* X unit types can only be used in slot 2, and are actually
 	 part of a 2-slot L-X instruction.  We refuse to insert
@@ -777,7 +777,7 @@ ia64_memory_remove_breakpoint (struct gdbarch *gdbarch,
       do_cleanups (cleanup);
       return -1;
     }
-  if (template_encoding_table[template][slotnum] == L)
+  if (template_encoding_table[templ][slotnum] == L)
     {
       /* L unit types can only be used in slot 1.  But the breakpoint
 	 was actually saved using slot 2, so update the slot number
@@ -830,7 +830,7 @@ ia64_breakpoint_from_pc (struct gdbarch *gdbarch,
   int slotnum = (int) (*pcptr & 0x0f) / SLOT_MULTIPLIER, shadow_slotnum;
   long long instr_fetched;
   int val;
-  int template;
+  int templ;
   struct cleanup *cleanup;
 
   if (slotnum > 2)
@@ -858,13 +858,13 @@ ia64_breakpoint_from_pc (struct gdbarch *gdbarch,
 
   /* Check for L type instruction in slot 1, if present then bump up the slot
      number to the slot 2.  */
-  template = extract_bit_field (bundle, 0, 5);
-  if (template_encoding_table[template][slotnum] == X)
+  templ = extract_bit_field (bundle, 0, 5);
+  if (template_encoding_table[templ][slotnum] == X)
     {
       gdb_assert (slotnum == 2);
       error (_("Can't insert breakpoint for non-existing slot X"));
     }
-  if (template_encoding_table[template][slotnum] == L)
+  if (template_encoding_table[templ][slotnum] == L)
     {
       gdb_assert (slotnum == 1);
       slotnum = 2;
-- 
1.8.3.1


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]