]> granicus.if.org Git - clang/commitdiff
Fix build error in 371875
authorErich Keane <erich.keane@intel.com>
Fri, 13 Sep 2019 17:56:38 +0000 (17:56 +0000)
committerErich Keane <erich.keane@intel.com>
Fri, 13 Sep 2019 17:56:38 +0000 (17:56 +0000)
Apparently Clang complains about the name hiding here in a way that my
GCC build does not, so a shocking number of buildbots decided to tell me
about it.  Change the name of the variable to prevent the name hiding
and hope we don't have to fix this again.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@371876 91177308-0d34-0410-b5e6-96231b3b80d8

utils/TableGen/ClangAttrEmitter.cpp

index 3a180893ed606c4b230d6a0008537c7bf3977799..cf3f24ab521bfcf69901342587b70b2b3c4c1c03 100644 (file)
@@ -2341,7 +2341,7 @@ void EmitClangAttrClass(RecordKeeper &Records, raw_ostream &OS) {
       OS << ", SourceRange Range, AttributeCommonInfo::Syntax Syntax";
       if (!ElideSpelling)
         OS << ", " << R.getName()
-           << "Attr::Spelling Spelling = "
+           << "Attr::Spelling S = "
               "static_cast<Spelling>(SpellingNotCalculated)";
       OS << ") {\n";
       OS << "    AttributeCommonInfo I(Range, ";
@@ -2353,7 +2353,7 @@ void EmitClangAttrClass(RecordKeeper &Records, raw_ostream &OS) {
 
       OS << ", Syntax";
       if (!ElideSpelling)
-        OS << ", Spelling";
+        OS << ", S";
       OS << ");\n";
       OS << "    return Create";
       if (Implicit)