[cfe-commits] r72637 - in /cfe/trunk: include/clang/AST/DeclCXX.h include/clang/AST/DeclNodes.def lib/AST/DeclBase.cpp lib/AST/DeclCXX.cpp
Anders Carlsson
andersca at mac.com
Sat May 30 14:10:34 PDT 2009
Author: andersca
Date: Sat May 30 16:10:34 2009
New Revision: 72637
URL: http://llvm.org/viewvc/llvm-project?rev=72637&view=rev
Log:
Get rid of CXXTempVarDecl.
Modified:
cfe/trunk/include/clang/AST/DeclCXX.h
cfe/trunk/include/clang/AST/DeclNodes.def
cfe/trunk/lib/AST/DeclBase.cpp
cfe/trunk/lib/AST/DeclCXX.cpp
Modified: cfe/trunk/include/clang/AST/DeclCXX.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/DeclCXX.h?rev=72637&r1=72636&r2=72637&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/DeclCXX.h (original)
+++ cfe/trunk/include/clang/AST/DeclCXX.h Sat May 30 16:10:34 2009
@@ -1062,22 +1062,6 @@
static bool classof(StaticAssertDecl *D) { return true; }
};
-/// CXXTempVarDecl - Represents an implicit C++ temporary variable declaration.
-class CXXTempVarDecl : public VarDecl {
-protected:
- CXXTempVarDecl(DeclContext *DC, QualType T)
- : VarDecl(CXXTempVar, DC, SourceLocation(), 0, T, None) {}
-
-public:
- static CXXTempVarDecl *Create(ASTContext &C, DeclContext *DC,
- QualType T);
-
- static bool classof(const Decl *D) {
- return D->getKind() == Decl::CXXTempVar;
- }
- static bool classof(CXXTempVarDecl *D) { return true; }
-};
-
/// Insertion operator for diagnostics. This allows sending AccessSpecifier's
/// into a diagnostic with <<.
const DiagnosticBuilder &operator<<(const DiagnosticBuilder &DB,
Modified: cfe/trunk/include/clang/AST/DeclNodes.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/DeclNodes.def?rev=72637&r1=72636&r2=72637&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/DeclNodes.def (original)
+++ cfe/trunk/include/clang/AST/DeclNodes.def Sat May 30 16:10:34 2009
@@ -102,7 +102,6 @@
DECL(ParmVar, VarDecl)
DECL(OriginalParmVar, ParmVarDecl)
DECL(NonTypeTemplateParm, VarDecl)
- DECL(CXXTempVar, VarDecl)
DECL(Template, NamedDecl)
DECL(FunctionTemplate, TemplateDecl)
DECL(ClassTemplate, TemplateDecl)
Modified: cfe/trunk/lib/AST/DeclBase.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/DeclBase.cpp?rev=72637&r1=72636&r2=72637&view=diff
==============================================================================
--- cfe/trunk/lib/AST/DeclBase.cpp (original)
+++ cfe/trunk/lib/AST/DeclBase.cpp Sat May 30 16:10:34 2009
@@ -208,7 +208,6 @@
case ObjCForwardProtocol:
case Block:
case TranslationUnit:
- case CXXTempVar:
// Aren't looked up?
case UsingDirective:
Modified: cfe/trunk/lib/AST/DeclCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/DeclCXX.cpp?rev=72637&r1=72636&r2=72637&view=diff
==============================================================================
--- cfe/trunk/lib/AST/DeclCXX.cpp (original)
+++ cfe/trunk/lib/AST/DeclCXX.cpp Sat May 30 16:10:34 2009
@@ -439,15 +439,6 @@
StaticAssertDecl::~StaticAssertDecl() {
}
-CXXTempVarDecl *CXXTempVarDecl::Create(ASTContext &C, DeclContext *DC,
- QualType T) {
- assert((T->isDependentType() ||
- isa<CXXRecordDecl>(T->getAsRecordType()->getDecl())) &&
- "CXXTempVarDecl must either have a dependent type "
- "or a C++ record type!");
- return new (C) CXXTempVarDecl(DC, T);
-}
-
static const char *getAccessName(AccessSpecifier AS) {
switch (AS) {
default:
More information about the cfe-commits
mailing list