clang 20.0.0git
|
Pseudo declaration for capturing expressions. More...
#include "clang/AST/DeclOpenMP.h"
Public Member Functions | |
SourceRange | getSourceRange () const override LLVM_READONLY |
Source range that this declaration covers. | |
![]() | |
SourceRange | getSourceRange () const override LLVM_READONLY |
Source range that this declaration covers. | |
StorageClass | getStorageClass () const |
Returns the storage class as written in the source. | |
void | setStorageClass (StorageClass SC) |
void | setTSCSpec (ThreadStorageClassSpecifier TSC) |
ThreadStorageClassSpecifier | getTSCSpec () const |
TLSKind | getTLSKind () const |
bool | hasLocalStorage () const |
Returns true if a variable with function scope is a non-static local variable. | |
bool | isStaticLocal () const |
Returns true if a variable with function scope is a static local variable. | |
bool | hasExternalStorage () const |
Returns true if a variable has extern or private_extern storage. | |
bool | hasGlobalStorage () const |
Returns true for all variables that do not have local storage. | |
StorageDuration | getStorageDuration () const |
Get the storage duration of this variable, per C++ [basic.stc]. | |
LanguageLinkage | getLanguageLinkage () const |
Compute the language linkage. | |
bool | isExternC () const |
Determines whether this variable is a variable with external, C linkage. | |
bool | isInExternCContext () const |
Determines whether this variable's context is, or is nested within, a C++ extern "C" linkage spec. | |
bool | isInExternCXXContext () const |
Determines whether this variable's context is, or is nested within, a C++ extern "C++" linkage spec. | |
bool | isLocalVarDecl () const |
Returns true for local variable declarations other than parameters. | |
bool | isLocalVarDeclOrParm () const |
Similar to isLocalVarDecl but also includes parameters. | |
bool | isFunctionOrMethodVarDecl () const |
Similar to isLocalVarDecl, but excludes variables declared in blocks. | |
bool | isStaticDataMember () const |
Determines whether this is a static data member. | |
VarDecl * | getCanonicalDecl () override |
Retrieves the "canonical" declaration of the given declaration. | |
const VarDecl * | getCanonicalDecl () const |
DefinitionKind | isThisDeclarationADefinition (ASTContext &) const |
Check whether this declaration is a definition. | |
DefinitionKind | isThisDeclarationADefinition () const |
DefinitionKind | hasDefinition (ASTContext &) const |
Check whether this variable is defined in this translation unit. | |
DefinitionKind | hasDefinition () const |
VarDecl * | getActingDefinition () |
Get the tentative definition that acts as the real definition in a TU. | |
const VarDecl * | getActingDefinition () const |
VarDecl * | getDefinition (ASTContext &) |
Get the real (not just tentative) definition for this declaration. | |
const VarDecl * | getDefinition (ASTContext &C) const |
VarDecl * | getDefinition () |
const VarDecl * | getDefinition () const |
bool | isOutOfLine () const override |
Determine whether this is or was instantiated from an out-of-line definition of a static data member. | |
bool | isFileVarDecl () const |
Returns true for file scoped variable declaration. | |
const Expr * | getAnyInitializer () const |
Get the initializer for this variable, no matter which declaration it is attached to. | |
const Expr * | getAnyInitializer (const VarDecl *&D) const |
Get the initializer for this variable, no matter which declaration it is attached to. | |
bool | hasInit () const |
const Expr * | getInit () const |
Expr * | getInit () |
Stmt ** | getInitAddress () |
Retrieve the address of the initializer expression. | |
void | setInit (Expr *I) |
VarDecl * | getInitializingDeclaration () |
Get the initializing declaration of this variable, if any. | |
const VarDecl * | getInitializingDeclaration () const |
bool | mightBeUsableInConstantExpressions (const ASTContext &C) const |
Determine whether this variable's value might be usable in a constant expression, according to the relevant language standard. | |
bool | isUsableInConstantExpressions (const ASTContext &C) const |
Determine whether this variable's value can be used in a constant expression, according to the relevant language standard, including checking whether it was initialized by a constant expression. | |
EvaluatedStmt * | ensureEvaluatedStmt () const |
Convert the initializer for this declaration to the elaborated EvaluatedStmt form, which contains extra information on the evaluated value of the initializer. | |
EvaluatedStmt * | getEvaluatedStmt () const |
APValue * | evaluateValue () const |
Attempt to evaluate the value of the initializer attached to this declaration, and produce notes explaining why it cannot be evaluated. | |
APValue * | getEvaluatedValue () const |
Return the already-evaluated value of this variable's initializer, or NULL if the value is not yet known. | |
bool | evaluateDestruction (SmallVectorImpl< PartialDiagnosticAt > &Notes) const |
Evaluate the destruction of this variable to determine if it constitutes constant destruction. | |
bool | hasConstantInitialization () const |
Determine whether this variable has constant initialization. | |
bool | hasICEInitializer (const ASTContext &Context) const |
Determine whether the initializer of this variable is an integer constant expression. | |
bool | checkForConstantInitialization (SmallVectorImpl< PartialDiagnosticAt > &Notes) const |
Evaluate the initializer of this variable to determine whether it's a constant initializer. | |
void | setInitStyle (InitializationStyle Style) |
InitializationStyle | getInitStyle () const |
The style of initialization for this declaration. | |
bool | isDirectInit () const |
Whether the initializer is a direct-initializer (list or call). | |
bool | isThisDeclarationADemotedDefinition () const |
If this definition should pretend to be a declaration. | |
void | demoteThisDefinitionToDeclaration () |
This is a definition which should be demoted to a declaration. | |
bool | isExceptionVariable () const |
Determine whether this variable is the exception variable in a C++ catch statememt or an Objective-C @catch statement. | |
void | setExceptionVariable (bool EV) |
bool | isNRVOVariable () const |
Determine whether this local variable can be used with the named return value optimization (NRVO). | |
void | setNRVOVariable (bool NRVO) |
bool | isCXXForRangeDecl () const |
Determine whether this variable is the for-range-declaration in a C++0x for-range statement. | |
void | setCXXForRangeDecl (bool FRD) |
bool | isObjCForDecl () const |
Determine whether this variable is a for-loop declaration for a for-in statement in Objective-C. | |
void | setObjCForDecl (bool FRD) |
bool | isARCPseudoStrong () const |
Determine whether this variable is an ARC pseudo-__strong variable. | |
void | setARCPseudoStrong (bool PS) |
bool | isInline () const |
Whether this variable is (C++1z) inline. | |
bool | isInlineSpecified () const |
void | setInlineSpecified () |
void | setImplicitlyInline () |
bool | isConstexpr () const |
Whether this variable is (C++11) constexpr. | |
void | setConstexpr (bool IC) |
bool | isInitCapture () const |
Whether this variable is the implicit variable for a lambda init-capture. | |
void | setInitCapture (bool IC) |
bool | isParameterPack () const |
Determine whether this variable is actually a function parameter pack or init-capture pack. | |
bool | isPreviousDeclInSameBlockScope () const |
Whether this local extern variable declaration's previous declaration was declared in the same block scope. | |
void | setPreviousDeclInSameBlockScope (bool Same) |
bool | isEscapingByref () const |
Indicates the capture is a __block variable that is captured by a block that can potentially escape (a block for which BlockDecl::doesNotEscape returns false). | |
bool | isNonEscapingByref () const |
Indicates the capture is a __block variable that is never captured by an escaping block. | |
void | setEscapingByref () |
bool | isCXXCondDecl () const |
void | setCXXCondDecl () |
bool | hasDependentAlignment () const |
Determines if this variable's alignment is dependent. | |
VarDecl * | getTemplateInstantiationPattern () const |
Retrieve the variable declaration from which this variable could be instantiated, if it is an instantiation (rather than a non-template). | |
VarDecl * | getInstantiatedFromStaticDataMember () const |
If this variable is an instantiated static data member of a class template specialization, returns the templated static data member from which it was instantiated. | |
TemplateSpecializationKind | getTemplateSpecializationKind () const |
If this variable is an instantiation of a variable template or a static data member of a class template, determine what kind of template specialization or instantiation this is. | |
TemplateSpecializationKind | getTemplateSpecializationKindForInstantiation () const |
Get the template specialization kind of this variable for the purposes of template instantiation. | |
SourceLocation | getPointOfInstantiation () const |
If this variable is an instantiation of a variable template or a static data member of a class template, determine its point of instantiation. | |
MemberSpecializationInfo * | getMemberSpecializationInfo () const |
If this variable is an instantiation of a static data member of a class template specialization, retrieves the member specialization information. | |
void | setTemplateSpecializationKind (TemplateSpecializationKind TSK, SourceLocation PointOfInstantiation=SourceLocation()) |
For a static data member that was instantiated from a static data member of a class template, set the template specialiation kind. | |
void | setInstantiationOfStaticDataMember (VarDecl *VD, TemplateSpecializationKind TSK) |
Specify that this variable is an instantiation of the static data member VD. | |
VarTemplateDecl * | getDescribedVarTemplate () const |
Retrieves the variable template that is described by this variable declaration. | |
void | setDescribedVarTemplate (VarTemplateDecl *Template) |
bool | isKnownToBeDefined () const |
bool | isNoDestroy (const ASTContext &) const |
Is destruction of this variable entirely suppressed? If so, the variable need not have a usable destructor at all. | |
QualType::DestructionKind | needsDestruction (const ASTContext &Ctx) const |
Would the destruction of this variable have any effect, and if so, what kind? | |