26void OMPThreadPrivateDecl::anchor() {}
32 auto *D = OMPDeclarativeDirective::createDirective<OMPThreadPrivateDecl>(
33 C, DC, std::nullopt, VL.size(), L);
41 return OMPDeclarativeDirective::createEmptyDirective<OMPThreadPrivateDecl>(
47 "Number of variables is not the same as the preallocated buffer");
48 llvm::copy(VL, getVars().begin());
55void OMPAllocateDecl::anchor() { }
60 auto *D = OMPDeclarativeDirective::createDirective<OMPAllocateDecl>(
61 C, DC, CL, VL.size(), L);
69 return OMPDeclarativeDirective::createEmptyDirective<OMPAllocateDecl>(
75 "Number of variables is not the same as the preallocated buffer");
76 llvm::copy(VL, getVars().begin());
83void OMPRequiresDecl::anchor() {}
88 return OMPDeclarativeDirective::createDirective<OMPRequiresDecl>(
C, DC, CL, 0,
94 return OMPDeclarativeDirective::createEmptyDirective<OMPRequiresDecl>(
102OMPDeclareReductionDecl::OMPDeclareReductionDecl(
106 PrevDeclInScope(PrevDeclInScope) {
110void OMPDeclareReductionDecl::anchor() {}
127 return cast_or_null<OMPDeclareReductionDecl>(
132 return cast_or_null<OMPDeclareReductionDecl>(
140void OMPDeclareMapperDecl::anchor() {}
146 return OMPDeclarativeDirective::createDirective<OMPDeclareMapperDecl>(
147 C, DC, Clauses, 1, L, Name, T, VarName, PrevDeclInScope);
153 return OMPDeclarativeDirective::createEmptyDirective<OMPDeclareMapperDecl>(
159 return cast_or_null<OMPDeclareMapperDecl>(
164 return cast_or_null<OMPDeclareMapperDecl>(
172void OMPCapturedExprDecl::anchor() {}
178 C, DC,
Id, T,
C.getTrivialTypeSourceInfo(T), StartLoc);
Defines the clang::ASTContext interface.
This file defines OpenMP nodes for declarative directives.
Holds long-lived AST nodes (such as types and decls) that can be referred to throughout the semantic ...
DeclContext - This is used only as base class of specific decl types that can act as declaration cont...
SourceLocation getEndLoc() const LLVM_READONLY
ASTContext & getASTContext() const LLVM_READONLY
The name of a declaration.
SourceLocation getBeginLoc() const LLVM_READONLY
One of these records is kept for each identifier that is lexed.
This represents '#pragma omp allocate ...' directive.
static OMPAllocateDecl * Create(ASTContext &C, DeclContext *DC, SourceLocation L, ArrayRef< Expr * > VL, ArrayRef< OMPClause * > CL)
static OMPAllocateDecl * CreateDeserialized(ASTContext &C, unsigned ID, unsigned NVars, unsigned NClauses)
Pseudo declaration for capturing expressions.
static OMPCapturedExprDecl * Create(ASTContext &C, DeclContext *DC, IdentifierInfo *Id, QualType T, SourceLocation StartLoc)
static OMPCapturedExprDecl * CreateDeserialized(ASTContext &C, unsigned ID)
SourceRange getSourceRange() const override LLVM_READONLY
Source range that this declaration covers.
unsigned getNumChildren() const
OMPChildren * Data
Data, associated with the directive.
This represents '#pragma omp declare mapper ...' directive.
OMPDeclareMapperDecl * getPrevDeclInScope()
Get reference to previous declare mapper construct in the same scope with the same name.
static OMPDeclareMapperDecl * CreateDeserialized(ASTContext &C, unsigned ID, unsigned N)
Creates deserialized declare mapper node.
static OMPDeclareMapperDecl * Create(ASTContext &C, DeclContext *DC, SourceLocation L, DeclarationName Name, QualType T, DeclarationName VarName, ArrayRef< OMPClause * > Clauses, OMPDeclareMapperDecl *PrevDeclInScope)
Creates declare mapper node.
This represents '#pragma omp declare reduction ...' directive.
static OMPDeclareReductionDecl * CreateDeserialized(ASTContext &C, unsigned ID)
Create deserialized declare reduction node.
static OMPDeclareReductionDecl * Create(ASTContext &C, DeclContext *DC, SourceLocation L, DeclarationName Name, QualType T, OMPDeclareReductionDecl *PrevDeclInScope)
Create declare reduction node.
OMPDeclareReductionDecl * getPrevDeclInScope()
Get reference to previous declare reduction construct in the same scope with the same name.
This represents '#pragma omp requires...' directive.
static OMPRequiresDecl * CreateDeserialized(ASTContext &C, unsigned ID, unsigned N)
Create deserialized requires node.
static OMPRequiresDecl * Create(ASTContext &C, DeclContext *DC, SourceLocation L, ArrayRef< OMPClause * > CL)
Create requires node.
This represents '#pragma omp threadprivate ...' directive.
static OMPThreadPrivateDecl * Create(ASTContext &C, DeclContext *DC, SourceLocation L, ArrayRef< Expr * > VL)
static OMPThreadPrivateDecl * CreateDeserialized(ASTContext &C, unsigned ID, unsigned N)
A (possibly-)qualified type.
Encodes a location in the source.
A trivial tuple used to represent a source range.
Represent the declaration of a variable (in which case it is an lvalue) a function (in which case it ...
const Expr * getInit() const
T * get(ExternalASTSource *Source) const
Retrieve the pointer to the AST node that this lazy pointer points to.