[cfe-commits] r67128 - /cfe/trunk/lib/Sema/SemaDecl.cpp

Chris Lattner sabre at nondot.org
Tue Mar 17 16:17:13 PDT 2009


Author: lattner
Date: Tue Mar 17 18:17:04 2009
New Revision: 67128

URL: http://llvm.org/viewvc/llvm-project?rev=67128&view=rev
Log:
pull a nested conditional + comment out into its own variable,
no functionality change.

Modified:
    cfe/trunk/lib/Sema/SemaDecl.cpp

Modified: cfe/trunk/lib/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDecl.cpp?rev=67128&r1=67127&r2=67128&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDecl.cpp Tue Mar 17 18:17:04 2009
@@ -1845,13 +1845,13 @@
 
     isVirtualOkay = (SC != FunctionDecl::Static);
   } else {
+    bool HasPrototype =
+       getLangOptions().CPlusPlus ||
+       (D.getNumTypeObjects() && D.getTypeObject(0).Fun.hasPrototype);
+    
     NewFD = FunctionDecl::Create(Context, DC,
                                  D.getIdentifierLoc(),
-                                 Name, R, SC, isInline, 
-                                 /*hasPrototype=*/
-                                   (getLangOptions().CPlusPlus ||
-                                    (D.getNumTypeObjects() &&
-                                     D.getTypeObject(0).Fun.hasPrototype)),
+                                 Name, R, SC, isInline, HasPrototype,
                                  // FIXME: Move to DeclGroup...
                                  D.getDeclSpec().getSourceRange().getBegin());
   }





More information about the cfe-commits mailing list