clang API Documentation
#include <Decl.h>
Public Member Functions | |
LabelStmt * | getStmt () const |
void | setStmt (LabelStmt *T) |
bool | isGnuLocal () const |
void | setLocStart (SourceLocation L) |
SourceRange | getSourceRange () const override LLVM_READONLY |
Source range that this declaration covers. | |
bool | isMSAsmLabel () const |
bool | isResolvedMSAsmLabel () const |
void | setMSAsmLabel (StringRef Name) |
StringRef | getMSAsmLabel () const |
void | setMSAsmLabelResolved () |
Static Public Member Functions | |
static LabelDecl * | Create (ASTContext &C, DeclContext *DC, SourceLocation IdentL, IdentifierInfo *II) |
static LabelDecl * | Create (ASTContext &C, DeclContext *DC, SourceLocation IdentL, IdentifierInfo *II, SourceLocation GnuLabelL) |
static LabelDecl * | CreateDeserialized (ASTContext &C, unsigned ID) |
static bool | classof (const Decl *D) |
static bool | classofKind (Kind K) |
LabelDecl - Represents the declaration of a label. Labels also have a corresponding LabelStmt, which indicates the position that the label was defined at. For normal labels, the location of the decl is the same as the location of the statement. For GNU local labels (__label__), the decl location is where the __label__ is.
static bool clang::LabelDecl::classof | ( | const Decl * | D | ) | [inline, static] |
Reimplemented from clang::NamedDecl.
Definition at line 353 of file Decl.h.
References classofKind(), and clang::Decl::getKind().
static bool clang::LabelDecl::classofKind | ( | Kind | K | ) | [inline, static] |
Reimplemented from clang::NamedDecl.
Definition at line 354 of file Decl.h.
Referenced by classof().
LabelDecl * LabelDecl::Create | ( | ASTContext & | C, |
DeclContext * | DC, | ||
SourceLocation | IdentL, | ||
IdentifierInfo * | II | ||
) | [static] |
Definition at line 3732 of file Decl.cpp.
References AttributeLangSupport::C.
Referenced by clang::Sema::LookupOrCreateLabel().
LabelDecl * LabelDecl::Create | ( | ASTContext & | C, |
DeclContext * | DC, | ||
SourceLocation | IdentL, | ||
IdentifierInfo * | II, | ||
SourceLocation | GnuLabelL | ||
) | [static] |
Definition at line 3737 of file Decl.cpp.
References AttributeLangSupport::C.
LabelDecl * LabelDecl::CreateDeserialized | ( | ASTContext & | C, |
unsigned | ID | ||
) | [static] |
Definition at line 3744 of file Decl.cpp.
References AttributeLangSupport::C.
StringRef clang::LabelDecl::getMSAsmLabel | ( | ) | const [inline] |
SourceRange clang::LabelDecl::getSourceRange | ( | ) | const [inline, override, virtual] |
Source range that this declaration covers.
Reimplemented from clang::Decl.
Definition at line 342 of file Decl.h.
References clang::Decl::getLocation().
LabelStmt* clang::LabelDecl::getStmt | ( | ) | const [inline] |
Definition at line 336 of file Decl.h.
Referenced by clang::Sema::ActOnLabelStmt(), CheckPoppedLabel(), DiagnoseIndirectJumpStmt(), and clang::CodeGen::CodeGenFunction::EmitLabel().
bool clang::LabelDecl::isGnuLocal | ( | ) | const [inline] |
Definition at line 339 of file Decl.h.
References clang::Decl::getLocation().
Referenced by clang::Sema::ActOnLabelStmt().
bool clang::LabelDecl::isMSAsmLabel | ( | ) | const [inline] |
Definition at line 346 of file Decl.h.
Referenced by clang::Sema::ActOnLabelStmt(), CheckPoppedLabel(), clang::Sema::GetOrCreateMSAsmLabel(), and isResolvedMSAsmLabel().
bool clang::LabelDecl::isResolvedMSAsmLabel | ( | ) | const [inline] |
void clang::LabelDecl::setLocStart | ( | SourceLocation | L | ) | [inline] |
Definition at line 340 of file Decl.h.
Referenced by clang::Sema::ActOnLabelStmt(), and clang::ASTDeclReader::VisitLabelDecl().
void LabelDecl::setMSAsmLabel | ( | StringRef | Name | ) |
Definition at line 3749 of file Decl.cpp.
References clang::Decl::getASTContext().
Referenced by clang::Sema::GetOrCreateMSAsmLabel().
void clang::LabelDecl::setMSAsmLabelResolved | ( | ) | [inline] |
Definition at line 350 of file Decl.h.
Referenced by clang::Sema::GetOrCreateMSAsmLabel().
void clang::LabelDecl::setStmt | ( | LabelStmt * | T | ) | [inline] |
Definition at line 337 of file Decl.h.
Referenced by clang::Sema::ActOnLabelStmt().