summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2020-01-14 15:46:13 +0100
committerDmitri Gribenko <gribozavr@gmail.com>2020-01-14 18:56:29 +0100
commit2948ec5ca98f8593584f2117bc92fe8d75f6f098 (patch)
tree417b18aa594f1db005b57eca3c27eb9ca0517427 /clang
parent0877843ddacca0bea049b65d8a328e5038c72b66 (diff)
downloadbcm5719-llvm-2948ec5ca98f8593584f2117bc92fe8d75f6f098.tar.gz
bcm5719-llvm-2948ec5ca98f8593584f2117bc92fe8d75f6f098.zip
Removed PointerUnion3 and PointerUnion4 aliases in favor of the variadic template
Diffstat (limited to 'clang')
-rw-r--r--clang/include/clang/AST/Decl.h8
-rw-r--r--clang/include/clang/AST/DeclCXX.h4
-rwxr-xr-xclang/include/clang/AST/DeclTemplate.h6
-rw-r--r--clang/include/clang/AST/ExprObjC.h2
-rw-r--r--clang/include/clang/AST/TemplateName.h4
-rw-r--r--clang/lib/AST/ASTContext.cpp8
-rw-r--r--clang/tools/libclang/CXCursor.h6
-rw-r--r--clang/unittests/CodeGen/IRMatchers.h2
8 files changed, 20 insertions, 20 deletions
diff --git a/clang/include/clang/AST/Decl.h b/clang/include/clang/AST/Decl.h
index 623f47b31bb..43c6c7b85db 100644
--- a/clang/include/clang/AST/Decl.h
+++ b/clang/include/clang/AST/Decl.h
@@ -1859,10 +1859,10 @@ private:
/// FunctionTemplateSpecializationInfo, which contains information about
/// the template being specialized and the template arguments involved in
/// that specialization.
- llvm::PointerUnion4<FunctionTemplateDecl *,
- MemberSpecializationInfo *,
- FunctionTemplateSpecializationInfo *,
- DependentFunctionTemplateSpecializationInfo *>
+ llvm::PointerUnion<FunctionTemplateDecl *,
+ MemberSpecializationInfo *,
+ FunctionTemplateSpecializationInfo *,
+ DependentFunctionTemplateSpecializationInfo *>
TemplateOrSpecialization;
/// Provides source/type location info for the declaration name embedded in
diff --git a/clang/include/clang/AST/DeclCXX.h b/clang/include/clang/AST/DeclCXX.h
index 73b4fb94a49..b716ea453a5 100644
--- a/clang/include/clang/AST/DeclCXX.h
+++ b/clang/include/clang/AST/DeclCXX.h
@@ -2125,8 +2125,8 @@ class CXXCtorInitializer final {
/// Either the base class name/delegating constructor type (stored as
/// a TypeSourceInfo*), an normal field (FieldDecl), or an anonymous field
/// (IndirectFieldDecl*) being initialized.
- llvm::PointerUnion3<TypeSourceInfo *, FieldDecl *, IndirectFieldDecl *>
- Initializee;
+ llvm::PointerUnion<TypeSourceInfo *, FieldDecl *, IndirectFieldDecl *>
+ Initializee;
/// The source location for the field name or, for a base initializer
/// pack expansion, the location of the ellipsis.
diff --git a/clang/include/clang/AST/DeclTemplate.h b/clang/include/clang/AST/DeclTemplate.h
index 8b2c271fbf2..23905d12c8b 100755
--- a/clang/include/clang/AST/DeclTemplate.h
+++ b/clang/include/clang/AST/DeclTemplate.h
@@ -57,8 +57,8 @@ class VarTemplatePartialSpecializationDecl;
/// Stores a template parameter of any kind.
using TemplateParameter =
- llvm::PointerUnion3<TemplateTypeParmDecl *, NonTypeTemplateParmDecl *,
- TemplateTemplateParmDecl *>;
+ llvm::PointerUnion<TemplateTypeParmDecl *, NonTypeTemplateParmDecl *,
+ TemplateTemplateParmDecl *>;
NamedDecl *getAsNamedDecl(TemplateParameter P);
@@ -309,7 +309,7 @@ class DefaultArgStorage {
static_assert(sizeof(Chain) == sizeof(void *) * 2,
"non-pointer argument type?");
- llvm::PointerUnion3<ArgType, ParmDecl*, Chain*> ValueOrInherited;
+ llvm::PointerUnion<ArgType, ParmDecl*, Chain*> ValueOrInherited;
static ParmDecl *getParmOwningDefaultArg(ParmDecl *Parm) {
const DefaultArgStorage &Storage = Parm->getDefaultArgStorage();
diff --git a/clang/include/clang/AST/ExprObjC.h b/clang/include/clang/AST/ExprObjC.h
index dbb2b2ff709..d76b3a26b1f 100644
--- a/clang/include/clang/AST/ExprObjC.h
+++ b/clang/include/clang/AST/ExprObjC.h
@@ -642,7 +642,7 @@ private:
/// the location of the 'super' keyword. When it's an interface,
/// this is that interface.
SourceLocation ReceiverLoc;
- llvm::PointerUnion3<Stmt *, const Type *, ObjCInterfaceDecl *> Receiver;
+ llvm::PointerUnion<Stmt *, const Type *, ObjCInterfaceDecl *> Receiver;
public:
ObjCPropertyRefExpr(ObjCPropertyDecl *PD, QualType t,
diff --git a/clang/include/clang/AST/TemplateName.h b/clang/include/clang/AST/TemplateName.h
index e99f1212116..cbbcbf6af8a 100644
--- a/clang/include/clang/AST/TemplateName.h
+++ b/clang/include/clang/AST/TemplateName.h
@@ -190,8 +190,8 @@ public:
/// only be understood in the context of
class TemplateName {
using StorageType =
- llvm::PointerUnion4<TemplateDecl *, UncommonTemplateNameStorage *,
- QualifiedTemplateName *, DependentTemplateName *>;
+ llvm::PointerUnion<TemplateDecl *, UncommonTemplateNameStorage *,
+ QualifiedTemplateName *, DependentTemplateName *>;
StorageType Storage;
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index 481affafc87..26e76d45042 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -924,15 +924,15 @@ class ASTContext::ParentMap {
/// only storing a unique pointer to them.
using ParentMapPointers = llvm::DenseMap<
const void *,
- llvm::PointerUnion4<const Decl *, const Stmt *,
- ast_type_traits::DynTypedNode *, ParentVector *>>;
+ llvm::PointerUnion<const Decl *, const Stmt *,
+ ast_type_traits::DynTypedNode *, ParentVector *>>;
/// Parent map for nodes without pointer identity. We store a full
/// DynTypedNode for all keys.
using ParentMapOtherNodes = llvm::DenseMap<
ast_type_traits::DynTypedNode,
- llvm::PointerUnion4<const Decl *, const Stmt *,
- ast_type_traits::DynTypedNode *, ParentVector *>>;
+ llvm::PointerUnion<const Decl *, const Stmt *,
+ ast_type_traits::DynTypedNode *, ParentVector *>>;
ParentMapPointers PointerParents;
ParentMapOtherNodes OtherParents;
diff --git a/clang/tools/libclang/CXCursor.h b/clang/tools/libclang/CXCursor.h
index d17381ba0ac..78e597b2bbe 100644
--- a/clang/tools/libclang/CXCursor.h
+++ b/clang/tools/libclang/CXCursor.h
@@ -228,9 +228,9 @@ CXCursor MakeCursorOverloadedDeclRef(TemplateName Template,
CXTranslationUnit TU);
/// Internal storage for an overloaded declaration reference cursor;
-typedef llvm::PointerUnion3<const OverloadExpr *, const Decl *,
- OverloadedTemplateStorage *>
- OverloadedDeclRefStorage;
+typedef llvm::PointerUnion<const OverloadExpr *, const Decl *,
+ OverloadedTemplateStorage *>
+ OverloadedDeclRefStorage;
/// Unpack an overloaded declaration reference into an expression,
/// declaration, or template name along with the source location.
diff --git a/clang/unittests/CodeGen/IRMatchers.h b/clang/unittests/CodeGen/IRMatchers.h
index 25bd1d5aa95..47e42049803 100644
--- a/clang/unittests/CodeGen/IRMatchers.h
+++ b/clang/unittests/CodeGen/IRMatchers.h
@@ -58,7 +58,7 @@ public:
/// the query also keeps the entity number in that list.
///
class Query {
- PointerUnion3<const Value *, const Metadata *, const Type *> Entity;
+ PointerUnion<const Value *, const Metadata *, const Type *> Entity;
unsigned OperandNo;
public:
OpenPOWER on IntegriCloud