r228424 - ASTUnit: Fix a name clash in GCC builds.

Benjamin Kramer benny.kra at googlemail.com
Fri Feb 6 10:58:04 PST 2015


Author: d0k
Date: Fri Feb  6 12:58:04 2015
New Revision: 228424

URL: http://llvm.org/viewvc/llvm-project?rev=228424&view=rev
Log:
ASTUnit: Fix a name clash in GCC builds.

Should fix the build. Looks like GCC 4.9 is using different scoping rules for
range-based for loops.

Modified:
    cfe/trunk/lib/Frontend/ASTUnit.cpp

Modified: cfe/trunk/lib/Frontend/ASTUnit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=228424&r1=228423&r2=228424&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/ASTUnit.cpp (original)
+++ cfe/trunk/lib/Frontend/ASTUnit.cpp Fri Feb  6 12:58:04 2015
@@ -924,8 +924,8 @@ public:
     Hash = 0;
   }
 
-  bool HandleTopLevelDecl(DeclGroupRef D) override {
-    for (Decl *D : D) {
+  bool HandleTopLevelDecl(DeclGroupRef DG) override {
+    for (Decl *D : DG) {
       // FIXME: Currently ObjC method declarations are incorrectly being
       // reported as top-level declarations, even though their DeclContext
       // is the containing ObjC @interface/@implementation.  This is a





More information about the cfe-commits mailing list