[cfe-commits] r115723 - /cfe/trunk/lib/Sema/SemaType.cpp

Fariborz Jahanian fjahanian at apple.com
Tue Oct 5 17:23:25 PDT 2010


Author: fjahanian
Date: Tue Oct  5 19:23:25 2010
New Revision: 115723

URL: http://llvm.org/viewvc/llvm-project?rev=115723&view=rev
Log:
Ue TagType, added a FIXME. Per John's comment.


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

Modified: cfe/trunk/lib/Sema/SemaType.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaType.cpp?rev=115723&r1=115722&r2=115723&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaType.cpp (original)
+++ cfe/trunk/lib/Sema/SemaType.cpp Tue Oct  5 19:23:25 2010
@@ -2213,10 +2213,9 @@
   }
   if (!E->isTypeDependent()) {
     QualType T = E->getType();
-    if (const RecordType *EltTy = T->getAs<RecordType>())
-      DiagnoseUseOfDecl(EltTy->getDecl(), E->getExprLoc());
-    else if (const EnumType *Enum = T->getAs<EnumType>())
-      DiagnoseUseOfDecl(Enum->getDecl(), E->getExprLoc());
+    // FIXME. Issue warning for types built from deprecated types as well.
+    if (const TagType *TT = T->getAs<TagType>())
+      DiagnoseUseOfDecl(TT->getDecl(), E->getExprLoc());
   }
   return Context.getTypeOfExprType(E);
 }





More information about the cfe-commits mailing list