Rename `typename' in d-exp.y to avoid C++ reserved word
authorKeith Seitz <keiths@redhat.com>
Sat, 15 Aug 2015 00:28:11 +0000 (17:28 -0700)
committerKeith Seitz <keiths@redhat.com>
Sat, 15 Aug 2015 00:28:11 +0000 (17:28 -0700)
A recent patch introduced a variable named `typename' into d-exp.y,
and one of the --enable-with-cxx build slaves consequently failed to compile
this.  This patch simply adds an underscore into the name to avoid the
reserved word.

gdb/ChangeLog

* d-exp.y (PrimaryExpression : TypeExp '.' IdentifierExp): Rename
`typename' to `type_name' to avoid C++ reserved word.

gdb/ChangeLog
gdb/d-exp.y

index 0b604fdfc308f3c49bc04a44ad937b59e9663b3f..d699070d6141dbac2b61f599ee18ed53a018befd 100644 (file)
@@ -1,3 +1,8 @@
+2015-08-14  Keith Seitz  <keiths@redhat.com>
+
+       * d-exp.y (PrimaryExpression : TypeExp '.' IdentifierExp): Rename
+       `typename' to `type_name' to avoid C++ reserved word.
+
 2015-08-14  Keith Seitz  <keiths@redhat.com>
 
        * location.c (EL_TYPE, EL_LINESPEC, EL_PROBE, EL_ADDRESS)
index e23a0aaeeaec07876a12befb9096d2394b979fa8..e9d21ac50d2e9a10a9a9147ff49ee6dcbf98da2a 100644 (file)
@@ -522,12 +522,12 @@ PrimaryExpression:
                            {
                              struct bound_minimal_symbol msymbol;
                              struct block_symbol sym;
-                             const char *typename = TYPE_SAFE_NAME (type);
-                             int typename_len = strlen (typename);
+                             const char *type_name = TYPE_SAFE_NAME (type);
+                             int type_name_len = strlen (type_name);
                              char *name;
 
                              name = xstrprintf ("%.*s.%.*s",
-                                                typename_len, typename,
+                                                type_name_len, type_name,
                                                 $3.length, $3.ptr);
                              make_cleanup (xfree, name);
 
This page took 0.028238 seconds and 4 git commands to generate.