[cfe-commits] r67543 - /cfe/trunk/lib/AST/Expr.cpp

Chris Lattner sabre at nondot.org
Mon Mar 23 10:57:53 PDT 2009


Author: lattner
Date: Mon Mar 23 12:57:53 2009
New Revision: 67543

URL: http://llvm.org/viewvc/llvm-project?rev=67543&view=rev
Log:
use isa<>

Modified:
    cfe/trunk/lib/AST/Expr.cpp

Modified: cfe/trunk/lib/AST/Expr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/Expr.cpp?rev=67543&r1=67542&r2=67543&view=diff

==============================================================================
--- cfe/trunk/lib/AST/Expr.cpp (original)
+++ cfe/trunk/lib/AST/Expr.cpp Mon Mar 23 12:57:53 2009
@@ -786,7 +786,7 @@
   //   void takeclosure(void (^C)(void));
   //   void func() { int x = 1; takeclosure(^{ x = 7; }); }
   //
-  if (getStmtClass() == BlockDeclRefExprClass) {
+  if (isa<BlockDeclRefExpr>(this)) {
     const BlockDeclRefExpr *BDR = cast<BlockDeclRefExpr>(this);
     if (!BDR->isByRef() && isa<VarDecl>(BDR->getDecl()))
       return MLV_NotBlockQualified;
@@ -807,7 +807,7 @@
   }
   
   // Assigning to an 'implicit' property?
-  else if (getStmtClass() == ObjCKVCRefExprClass) {
+  else if (isa<ObjCKVCRefExpr>(this)) {
     const ObjCKVCRefExpr* KVCExpr = cast<ObjCKVCRefExpr>(this);
     if (KVCExpr->getSetterMethod() == 0)
       return MLV_NoSetterProperty;





More information about the cfe-commits mailing list