clang 22.0.0git
IdentifierTable.h File Reference

Defines the clang::IdentifierInfo, clang::IdentifierTable, and clang::Selector interfaces. More...

#include "clang/Basic/Builtins.h"
#include "clang/Basic/DiagnosticIDs.h"
#include "clang/Basic/LLVM.h"
#include "clang/Basic/SourceLocation.h"
#include "clang/Basic/TokenKinds.h"
#include "llvm/ADT/DenseMapInfo.h"
#include "llvm/ADT/FoldingSet.h"
#include "llvm/ADT/PointerIntPair.h"
#include "llvm/ADT/PointerUnion.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Allocator.h"
#include "llvm/Support/PointerLikeTypeTraits.h"
#include "llvm/Support/type_traits.h"
#include <cassert>
#include <cstddef>
#include <cstdint>
#include <cstring>
#include <string>
#include <utility>
#include "clang/Basic/TokenKinds.def"
#include "clang/Basic/Builtins.inc"

Go to the source code of this file.

Classes

class  clang::IdentifierInfo
 One of these records is kept for each identifier that is lexed. More...
class  clang::PoisonIdentifierRAIIObject
 An RAII object for [un]poisoning an identifier within a scope. More...
class  clang::IdentifierIterator
 An iterator that walks over all of the known identifiers in the lookup table. More...
class  clang::IdentifierInfoLookup
 Provides lookups to, and iteration over, IdentiferInfo objects. More...
class  clang::IdentifierTable
 Implements an efficient mapping from strings to IdentifierInfo nodes. More...
class  clang::detail::DeclarationNameExtra
 DeclarationNameExtra is used as a base of various uncommon special names. More...
class  clang::MultiKeywordSelector
 One of these variable length records is kept for each selector containing more than one keyword. More...
class  clang::Selector
 Smart pointer class that efficiently represents Objective-C method names. More...
class  clang::SelectorTable
 This table allows us to fully hide how we implement multi-keyword caching. More...
class  clang::IdentifierLoc
 A simple pair of identifier info and location. More...
struct  llvm::DenseMapInfo< clang::Selector >
 Define DenseMapInfo so that Selectors can be used as keys in DenseMap and DenseSets. More...
struct  llvm::PointerLikeTypeTraits< clang::Selector >

Namespaces

namespace  clang
 The JSON file list parser is used to communicate input to InstallAPI.
namespace  clang::detail
namespace  llvm
 Diagnostic wrappers for TextAPI types for error reporting.

Macros

#define OBJC_AT_KEYWORD(X)
#define NOTABLE_IDENTIFIER(X)
#define GET_BUILTIN_ENUMERATORS

Enumerations

enum  clang::TokenKey : unsigned {
  clang::KEYC99 = 0x1 , clang::KEYCXX = 0x2 , clang::KEYCXX11 = 0x4 , clang::KEYGNU = 0x8 ,
  clang::KEYMS = 0x10 , clang::BOOLSUPPORT = 0x20 , clang::KEYALTIVEC = 0x40 , clang::KEYNOCXX = 0x80 ,
  clang::KEYBORLAND = 0x100 , clang::KEYOPENCLC = 0x200 , clang::KEYC23 = 0x400 , clang::KEYNOMS18 = 0x800 ,
  clang::KEYNOOPENCL = 0x1000 , clang::WCHARSUPPORT = 0x2000 , clang::HALFSUPPORT = 0x4000 , clang::CHAR8SUPPORT = 0x8000 ,
  clang::KEYOBJC = 0x10000 , clang::KEYZVECTOR = 0x20000 , clang::KEYCOROUTINES = 0x40000 , clang::KEYMODULES = 0x80000 ,
  clang::KEYCXX20 = 0x100000 , clang::KEYOPENCLCXX = 0x200000 , clang::KEYMSCOMPAT = 0x400000 , clang::KEYSYCL = 0x800000 ,
  clang::KEYCUDA = 0x1000000 , clang::KEYZOS = 0x2000000 , clang::KEYNOZOS = 0x4000000 , clang::KEYHLSL = 0x8000000 ,
  clang::KEYFIXEDPOINT = 0x10000000 , clang::KEYMAX = KEYFIXEDPOINT , clang::KEYALLCXX = KEYCXX | KEYCXX11 | KEYCXX20 , clang::KEYALL
}
 Constants for TokenKinds.def. More...
enum  clang::KeywordStatus {
  clang::KS_Unknown , clang::KS_Disabled , clang::KS_Future , clang::KS_Extension ,
  clang::KS_Enabled
}
 How a keyword is treated in the selected standard. More...
enum class  clang::ReservedIdentifierStatus {
  clang::NotReserved = 0 , clang::StartsWithUnderscoreAtGlobalScope , clang::StartsWithUnderscoreAndIsExternC , clang::StartsWithDoubleUnderscore ,
  clang::StartsWithUnderscoreFollowedByCapitalLetter , clang::ContainsDoubleUnderscore
}
enum class  clang::ReservedLiteralSuffixIdStatus { clang::NotReserved = 0 , clang::NotStartsWithUnderscore , clang::ContainsDoubleUnderscore }
enum  { clang::IdentifierInfoAlignment = 8 }
 IdentifierInfo and other related classes are aligned to 8 bytes so that DeclarationName can use the lower 3 bits of a pointer to one of these classes. More...
enum class  clang::InterestingIdentifier {
  clang::NUM_OBJC_KEYWORDS , clang::NUM_OBJC_KEYWORDS_AND_NOTABLE_IDENTIFIERS , clang::NotBuiltin , clang::FirstTSBuiltin ,
  clang::NotInterestingIdentifier = 65534
}
 The "layout" of InterestingIdentifier is: More...
enum  clang::ObjCMethodFamily {
  clang::OMF_None , clang::OMF_alloc , clang::OMF_copy , clang::OMF_init ,
  clang::OMF_mutableCopy , clang::OMF_new , clang::OMF_autorelease , clang::OMF_dealloc ,
  clang::OMF_finalize , clang::OMF_release , clang::OMF_retain , clang::OMF_retainCount ,
  clang::OMF_self , clang::OMF_initialize , clang::OMF_performSelector
}
 A family of Objective-C methods. More...
enum  { clang::ObjCMethodFamilyBitWidth = 4 }
 Enough bits to store any enumerator in ObjCMethodFamily or InvalidObjCMethodFamily. More...
enum  { clang::InvalidObjCMethodFamily = (1 << ObjCMethodFamilyBitWidth) - 1 }
 An invalid value of ObjCMethodFamily. More...
enum  clang::ObjCInstanceTypeFamily {
  clang::OIT_None , clang::OIT_Array , clang::OIT_Dictionary , clang::OIT_Singleton ,
  clang::OIT_Init , clang::OIT_ReturnsSelf
}
 A family of Objective-C methods. More...
enum  clang::ObjCStringFormatFamily { clang::SFF_None , clang::SFF_NSString , clang::SFF_CFString }

Functions

KeywordStatus clang::getKeywordStatus (const LangOptions &LangOpts, unsigned Flags)
 Translates flags as specified in TokenKinds.def into keyword status in the given language standard.
bool clang::isReservedAtGlobalScope (ReservedIdentifierStatus Status)
 Determine whether an identifier is reserved for use as a name at global scope.
bool clang::isReservedInAllContexts (ReservedIdentifierStatus Status)
 Determine whether an identifier is reserved in all contexts.

Variables

static constexpr int clang::InterestingIdentifierBits = 16

Detailed Description

Defines the clang::IdentifierInfo, clang::IdentifierTable, and clang::Selector interfaces.

Definition in file IdentifierTable.h.

Macro Definition Documentation

◆ GET_BUILTIN_ENUMERATORS

#define GET_BUILTIN_ENUMERATORS

Definition at line 153 of file IdentifierTable.h.

◆ NOTABLE_IDENTIFIER

#define NOTABLE_IDENTIFIER ( X)
Value:
X,
#define X(type, name)
Definition Value.h:97

Definition at line 148 of file IdentifierTable.h.

◆ OBJC_AT_KEYWORD

#define OBJC_AT_KEYWORD ( X)
Value:
objc_##X,

Definition at line 144 of file IdentifierTable.h.