[cfe-commits] r46947 - /cfe/trunk/Sema/SemaDecl.cpp

Steve Naroff snaroff at apple.com
Sun Feb 10 18:42:08 PST 2008


Author: snaroff
Date: Sun Feb 10 20:42:07 2008
New Revision: 46947

URL: http://llvm.org/viewvc/llvm-project?rev=46947&view=rev
Log:

Add a comment/FIXME to an earlier change.


Modified:
    cfe/trunk/Sema/SemaDecl.cpp

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

==============================================================================
--- cfe/trunk/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/Sema/SemaDecl.cpp Sun Feb 10 20:42:07 2008
@@ -527,7 +527,11 @@
       } else {
         RecordDecl* structDecl = DeclType->getAsRecordType()->getDecl();
         
-        // If the record is invalid, it's members can't be trusted. 
+        // If the record is invalid, it's members can't be trusted.
+        // FIXME: I'd like to "fix" this at a higher level. That is, we should
+        // never get here if the struct decl is invalid. Considering a
+        // change to Type::isIncompleteType(). Until this happens, the 
+        // following check is certainly better than crashing.
         if (structDecl->isInvalidDecl())
           return true;
           





More information about the cfe-commits mailing list