aboutsummaryrefslogtreecommitdiffstats
path: root/include/clang/AST/TypeLocNodes.def
diff options
context:
space:
mode:
Diffstat (limited to 'include/clang/AST/TypeLocNodes.def')
-rw-r--r--include/clang/AST/TypeLocNodes.def46
1 files changed, 12 insertions, 34 deletions
diff --git a/include/clang/AST/TypeLocNodes.def b/include/clang/AST/TypeLocNodes.def
index ecf7cc5c2995..4590e489e3f7 100644
--- a/include/clang/AST/TypeLocNodes.def
+++ b/include/clang/AST/TypeLocNodes.def
@@ -7,54 +7,32 @@
//
//===----------------------------------------------------------------------===//
//
-// This file defines the TypeLoc info database. Each node is
-// enumerated by providing its name (e.g., "PointerLoc" or "ArrayLoc"),
-// base class (e.g., "TypeSpecLoc" or "DeclaratorLoc"), and the Type subclass
-// that the TypeLoc is associated with.
+// This file defines the TypeLoc info database. Each node is
+// enumerated by providing its core name (e.g., "Pointer" for "PointerTypeLoc")
+// and base class (e.g., "DeclaratorLoc"). All nodes except QualifiedTypeLoc
+// are associated
//
-// TYPELOC(Class, Base) - A TypeLoc subclass.
+// TYPELOC(Class, Base) - A TypeLoc subclass. If UNQUAL_TYPELOC is
+// provided, there will be exactly one of these, Qualified.
//
// UNQUAL_TYPELOC(Class, Base, Type) - An UnqualTypeLoc subclass.
//
// ABSTRACT_TYPELOC(Class) - Refers to TypeSpecLoc and DeclaratorLoc.
//
-// TYPESPEC_TYPELOC(Class, Type) - A TypeLoc referring to a type-spec type.
-//
-// DECLARATOR_TYPELOC(Class, Type) - A TypeLoc referring to a type part of
-// a declarator, excluding type-spec types.
-//
//===----------------------------------------------------------------------===//
#ifndef UNQUAL_TYPELOC
-# define UNQUAL_TYPELOC(Class, Base, Type) TYPELOC(Class, Base)
+# define UNQUAL_TYPELOC(Class, Base) TYPELOC(Class, Base)
#endif
#ifndef ABSTRACT_TYPELOC
-# define ABSTRACT_TYPELOC(Class) TYPELOC(Class, TypeLoc)
-#endif
-
-#ifndef TYPESPEC_TYPELOC
-# define TYPESPEC_TYPELOC(Class, Type) UNQUAL_TYPELOC(Class, TypeSpecLoc, Type)
+# define ABSTRACT_TYPELOC(Class, Base) UNQUAL_TYPELOC(Class, Base)
#endif
-#ifndef DECLARATOR_TYPELOC
-# define DECLARATOR_TYPELOC(Class, Type) UNQUAL_TYPELOC(Class, DeclaratorLoc, Type)
-#endif
-
-TYPESPEC_TYPELOC(DefaultTypeSpecLoc, Type)
-TYPESPEC_TYPELOC(TypedefLoc, TypedefType)
-TYPESPEC_TYPELOC(ObjCInterfaceLoc, ObjCInterfaceType)
-TYPESPEC_TYPELOC(ObjCProtocolListLoc, ObjCProtocolListType)
-DECLARATOR_TYPELOC(PointerLoc, PointerType)
-DECLARATOR_TYPELOC(BlockPointerLoc, BlockPointerType)
-DECLARATOR_TYPELOC(MemberPointerLoc, MemberPointerType)
-DECLARATOR_TYPELOC(ReferenceLoc, ReferenceType)
-DECLARATOR_TYPELOC(FunctionLoc, FunctionType)
-DECLARATOR_TYPELOC(ArrayLoc, ArrayType)
-ABSTRACT_TYPELOC(DeclaratorLoc)
-ABSTRACT_TYPELOC(TypeSpecLoc)
-TYPELOC(QualifiedLoc, TypeLoc)
-
+TYPELOC(Qualified, TypeLoc)
+#define TYPE(Class, Base) UNQUAL_TYPELOC(Class, Base##Loc)
+#define ABSTRACT_TYPE(Class, Base) ABSTRACT_TYPELOC(Class, Base##Loc)
+#include "clang/AST/TypeNodes.def"
#undef DECLARATOR_TYPELOC
#undef TYPESPEC_TYPELOC