clang  6.0.0svn
ASTBitCodes.h
Go to the documentation of this file.
1 //===- ASTBitCodes.h - Enum values for the PCH bitcode format ---*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This header defines Bitcode enum values for Clang serialized AST files.
11 //
12 // The enum values defined in this file should be considered permanent. If
13 // new features are added, they should have values added at the end of the
14 // respective lists.
15 //
16 //===----------------------------------------------------------------------===//
17 
18 #ifndef LLVM_CLANG_SERIALIZATION_ASTBITCODES_H
19 #define LLVM_CLANG_SERIALIZATION_ASTBITCODES_H
20 
22 #include "clang/AST/Type.h"
26 #include "llvm/ADT/DenseMapInfo.h"
27 #include "llvm/Bitcode/BitCodes.h"
28 #include <cassert>
29 #include <cstdint>
30 
31 namespace clang {
32 namespace serialization {
33 
34  /// \brief AST file major version number supported by this version of
35  /// Clang.
36  ///
37  /// Whenever the AST file format changes in a way that makes it
38  /// incompatible with previous versions (such that a reader
39  /// designed for the previous version could not support reading
40  /// the new version), this number should be increased.
41  ///
42  /// Version 4 of AST files also requires that the version control branch and
43  /// revision match exactly, since there is no backward compatibility of
44  /// AST files at this time.
45  const unsigned VERSION_MAJOR = 6;
46 
47  /// \brief AST file minor version number supported by this version of
48  /// Clang.
49  ///
50  /// Whenever the AST format changes in a way that is still
51  /// compatible with previous versions (such that a reader designed
52  /// for the previous version could still support reading the new
53  /// version by ignoring new kinds of subblocks), this number
54  /// should be increased.
55  const unsigned VERSION_MINOR = 0;
56 
57  /// \brief An ID number that refers to an identifier in an AST file.
58  ///
59  /// The ID numbers of identifiers are consecutive (in order of discovery)
60  /// and start at 1. 0 is reserved for NULL.
61  using IdentifierID = uint32_t;
62 
63  /// \brief An ID number that refers to a declaration in an AST file.
64  ///
65  /// The ID numbers of declarations are consecutive (in order of
66  /// discovery), with values below NUM_PREDEF_DECL_IDS being reserved.
67  /// At the start of a chain of precompiled headers, declaration ID 1 is
68  /// used for the translation unit declaration.
69  using DeclID = uint32_t;
70 
71  // FIXME: Turn these into classes so we can have some type safety when
72  // we go from local ID to global and vice-versa.
75 
76  /// \brief An ID number that refers to a type in an AST file.
77  ///
78  /// The ID of a type is partitioned into two parts: the lower
79  /// three bits are used to store the const/volatile/restrict
80  /// qualifiers (as with QualType) and the upper bits provide a
81  /// type index. The type index values are partitioned into two
82  /// sets. The values below NUM_PREDEF_TYPE_IDs are predefined type
83  /// IDs (based on the PREDEF_TYPE_*_ID constants), with 0 as a
84  /// placeholder for "no type". Values from NUM_PREDEF_TYPE_IDs are
85  /// other types that have serialized representations.
86  using TypeID = uint32_t;
87 
88  /// \brief A type index; the type ID with the qualifier bits removed.
89  class TypeIdx {
90  uint32_t Idx = 0;
91 
92  public:
93  TypeIdx() = default;
94  explicit TypeIdx(uint32_t index) : Idx(index) {}
95 
96  uint32_t getIndex() const { return Idx; }
97 
98  TypeID asTypeID(unsigned FastQuals) const {
99  if (Idx == uint32_t(-1))
100  return TypeID(-1);
101 
102  return (Idx << Qualifiers::FastWidth) | FastQuals;
103  }
104 
106  if (ID == TypeID(-1))
107  return TypeIdx(-1);
108 
109  return TypeIdx(ID >> Qualifiers::FastWidth);
110  }
111  };
112 
113  /// A structure for putting "fast"-unqualified QualTypes into a
114  /// DenseMap. This uses the standard pointer hash function.
116  static bool isEqual(QualType A, QualType B) { return A == B; }
117 
119  return QualType::getFromOpaquePtr((void*) 1);
120  }
121 
123  return QualType::getFromOpaquePtr((void*) 2);
124  }
125 
126  static unsigned getHashValue(QualType T) {
127  assert(!T.getLocalFastQualifiers() &&
128  "hash invalid for types with fast quals");
129  uintptr_t v = reinterpret_cast<uintptr_t>(T.getAsOpaquePtr());
130  return (unsigned(v) >> 4) ^ (unsigned(v) >> 9);
131  }
132  };
133 
134  /// \brief An ID number that refers to an identifier in an AST file.
135  using IdentID = uint32_t;
136 
137  /// \brief The number of predefined identifier IDs.
138  const unsigned int NUM_PREDEF_IDENT_IDS = 1;
139 
140  /// \brief An ID number that refers to a macro in an AST file.
141  using MacroID = uint32_t;
142 
143  /// \brief A global ID number that refers to a macro in an AST file.
144  using GlobalMacroID = uint32_t;
145 
146  /// \brief A local to a module ID number that refers to a macro in an
147  /// AST file.
148  using LocalMacroID = uint32_t;
149 
150  /// \brief The number of predefined macro IDs.
151  const unsigned int NUM_PREDEF_MACRO_IDS = 1;
152 
153  /// \brief An ID number that refers to an ObjC selector in an AST file.
154  using SelectorID = uint32_t;
155 
156  /// \brief The number of predefined selector IDs.
157  const unsigned int NUM_PREDEF_SELECTOR_IDS = 1;
158 
159  /// \brief An ID number that refers to a set of CXXBaseSpecifiers in an
160  /// AST file.
161  using CXXBaseSpecifiersID = uint32_t;
162 
163  /// \brief An ID number that refers to a list of CXXCtorInitializers in an
164  /// AST file.
165  using CXXCtorInitializersID = uint32_t;
166 
167  /// \brief An ID number that refers to an entity in the detailed
168  /// preprocessing record.
169  using PreprocessedEntityID = uint32_t;
170 
171  /// \brief An ID number that refers to a submodule in a module file.
172  using SubmoduleID = uint32_t;
173 
174  /// \brief The number of predefined submodule IDs.
175  const unsigned int NUM_PREDEF_SUBMODULE_IDS = 1;
176 
177  /// \brief Source range/offset of a preprocessed entity.
178  struct PPEntityOffset {
179  /// \brief Raw source location of beginning of range.
180  unsigned Begin;
181 
182  /// \brief Raw source location of end of range.
183  unsigned End;
184 
185  /// \brief Offset in the AST file.
186  uint32_t BitOffset;
187 
188  PPEntityOffset(SourceRange R, uint32_t BitOffset)
189  : Begin(R.getBegin().getRawEncoding()),
190  End(R.getEnd().getRawEncoding()), BitOffset(BitOffset) {}
191 
194  }
195 
198  }
199  };
200 
201  /// \brief Source range/offset of a preprocessed entity.
202  struct DeclOffset {
203  /// \brief Raw source location.
204  unsigned Loc = 0;
205 
206  /// \brief Offset in the AST file.
207  uint32_t BitOffset = 0;
208 
209  DeclOffset() = default;
210  DeclOffset(SourceLocation Loc, uint32_t BitOffset)
211  : Loc(Loc.getRawEncoding()), BitOffset(BitOffset) {}
212 
214  Loc = L.getRawEncoding();
215  }
216 
219  }
220  };
221 
222  /// \brief The number of predefined preprocessed entity IDs.
223  const unsigned int NUM_PREDEF_PP_ENTITY_IDS = 1;
224 
225  /// \brief Describes the various kinds of blocks that occur within
226  /// an AST file.
227  enum BlockIDs {
228  /// \brief The AST block, which acts as a container around the
229  /// full AST block.
230  AST_BLOCK_ID = llvm::bitc::FIRST_APPLICATION_BLOCKID,
231 
232  /// \brief The block containing information about the source
233  /// manager.
235 
236  /// \brief The block containing information about the
237  /// preprocessor.
239 
240  /// \brief The block containing the definitions of all of the
241  /// types and decls used within the AST file.
243 
244  /// \brief The block containing the detailed preprocessing record.
246 
247  /// \brief The block containing the submodule structure.
249 
250  /// \brief The block containing comments.
252 
253  /// \brief The control block, which contains all of the
254  /// information that needs to be validated prior to committing
255  /// to loading the AST file.
257 
258  /// \brief The block of input files, which were used as inputs
259  /// to create this AST file.
260  ///
261  /// This block is part of the control block.
263 
264  /// \brief The block of configuration options, used to check that
265  /// a module is being used in a configuration compatible with the
266  /// configuration in which it was built.
267  ///
268  /// This block is part of the control block.
270 
271  /// \brief A block containing a module file extension.
273 
274  /// A block with unhashed content.
275  ///
276  /// These records should not change the \a ASTFileSignature. See \a
277  /// UnhashedControlBlockRecordTypes for the list of records.
279  };
280 
281  /// \brief Record types that occur within the control block.
283  /// \brief AST file metadata, including the AST file version number
284  /// and information about the compiler used to build this AST file.
285  METADATA = 1,
286 
287  /// \brief Record code for the list of other AST files imported by
288  /// this AST file.
290 
291  /// \brief Record code for the original file that was used to
292  /// generate the AST file, including both its file ID and its
293  /// name.
295 
296  /// \brief The directory that the PCH was originally created in.
298 
299  /// \brief Record code for file ID of the file or buffer that was used to
300  /// generate the AST file.
302 
303  /// \brief Offsets into the input-files block where input files
304  /// reside.
306 
307  /// \brief Record code for the module name.
309 
310  /// \brief Record code for the module map file that was used to build this
311  /// AST file.
313 
314  /// \brief Record code for the module build directory.
316  };
317 
318  /// \brief Record types that occur within the options block inside
319  /// the control block.
321  /// \brief Record code for the language options table.
322  ///
323  /// The record with this code contains the contents of the
324  /// LangOptions structure. We serialize the entire contents of
325  /// the structure, and let the reader decide which options are
326  /// actually important to check.
328 
329  /// \brief Record code for the target options table.
331 
332  /// \brief Record code for the filesystem options table.
334 
335  /// \brief Record code for the headers search options table.
337 
338  /// \brief Record code for the preprocessor options table.
340  };
341 
342  /// Record codes for the unhashed control block.
344  /// Record code for the signature that identifiers this AST file.
346 
347  /// Record code for the diagnostic options table.
349 
350  /// Record code for \#pragma diagnostic mappings.
352  };
353 
354  /// \brief Record code for extension blocks.
356  /// Metadata describing this particular extension.
358 
359  /// The first record ID allocated to the extensions themselves.
361  };
362 
363  /// \brief Record types that occur within the input-files block
364  /// inside the control block.
366  /// \brief An input file.
368  };
369 
370  /// \brief Record types that occur within the AST block itself.
372  /// \brief Record code for the offsets of each type.
373  ///
374  /// The TYPE_OFFSET constant describes the record that occurs
375  /// within the AST block. The record itself is an array of offsets that
376  /// point into the declarations and types block (identified by
377  /// DECLTYPES_BLOCK_ID). The index into the array is based on the ID
378  /// of a type. For a given type ID @c T, the lower three bits of
379  /// @c T are its qualifiers (const, volatile, restrict), as in
380  /// the QualType class. The upper bits, after being shifted and
381  /// subtracting NUM_PREDEF_TYPE_IDS, are used to index into the
382  /// TYPE_OFFSET block to determine the offset of that type's
383  /// corresponding record within the DECLTYPES_BLOCK_ID block.
385 
386  /// \brief Record code for the offsets of each decl.
387  ///
388  /// The DECL_OFFSET constant describes the record that occurs
389  /// within the block identified by DECL_OFFSETS_BLOCK_ID within
390  /// the AST block. The record itself is an array of offsets that
391  /// point into the declarations and types block (identified by
392  /// DECLTYPES_BLOCK_ID). The declaration ID is an index into this
393  /// record, after subtracting one to account for the use of
394  /// declaration ID 0 for a NULL declaration pointer. Index 0 is
395  /// reserved for the translation unit declaration.
397 
398  /// \brief Record code for the table of offsets of each
399  /// identifier ID.
400  ///
401  /// The offset table contains offsets into the blob stored in
402  /// the IDENTIFIER_TABLE record. Each offset points to the
403  /// NULL-terminated string that corresponds to that identifier.
405 
406  /// \brief This is so that older clang versions, before the introduction
407  /// of the control block, can read and reject the newer PCH format.
408  /// *DON'T CHANGE THIS NUMBER*.
410 
411  /// \brief Record code for the identifier table.
412  ///
413  /// The identifier table is a simple blob that contains
414  /// NULL-terminated strings for all of the identifiers
415  /// referenced by the AST file. The IDENTIFIER_OFFSET table
416  /// contains the mapping from identifier IDs to the characters
417  /// in this blob. Note that the starting offsets of all of the
418  /// identifiers are odd, so that, when the identifier offset
419  /// table is loaded in, we can use the low bit to distinguish
420  /// between offsets (for unresolved identifier IDs) and
421  /// IdentifierInfo pointers (for already-resolved identifier
422  /// IDs).
424 
425  /// \brief Record code for the array of eagerly deserialized decls.
426  ///
427  /// The AST file contains a list of all of the declarations that should be
428  /// eagerly deserialized present within the parsed headers, stored as an
429  /// array of declaration IDs. These declarations will be
430  /// reported to the AST consumer after the AST file has been
431  /// read, since their presence can affect the semantics of the
432  /// program (e.g., for code generation).
434 
435  /// \brief Record code for the set of non-builtin, special
436  /// types.
437  ///
438  /// This record contains the type IDs for the various type nodes
439  /// that are constructed during semantic analysis (e.g.,
440  /// __builtin_va_list). The SPECIAL_TYPE_* constants provide
441  /// offsets into this record.
443 
444  /// \brief Record code for the extra statistics we gather while
445  /// generating an AST file.
447 
448  /// \brief Record code for the array of tentative definitions.
450 
451  // ID 10 used to be for a list of extern "C" declarations.
452 
453  /// \brief Record code for the table of offsets into the
454  /// Objective-C method pool.
456 
457  /// \brief Record code for the Objective-C method pool,
459 
460  /// \brief The value of the next __COUNTER__ to dispense.
461  /// [PP_COUNTER_VALUE, Val]
463 
464  /// \brief Record code for the table of offsets into the block
465  /// of source-location information.
467 
468  /// \brief Record code for the set of source location entries
469  /// that need to be preloaded by the AST reader.
470  ///
471  /// This set contains the source location entry for the
472  /// predefines buffer and for any file entries that need to be
473  /// preloaded.
475 
476  /// \brief Record code for the set of ext_vector type names.
478 
479  /// \brief Record code for the array of unused file scoped decls.
481 
482  /// \brief Record code for the table of offsets to entries in the
483  /// preprocessing record.
485 
486  /// \brief Record code for the array of VTable uses.
488 
489  // ID 20 used to be for a list of dynamic classes.
490 
491  /// \brief Record code for referenced selector pool.
493 
494  /// \brief Record code for an update to the TU's lexically contained
495  /// declarations.
497 
498  // ID 23 used to be for a list of local redeclarations.
499 
500  /// \brief Record code for declarations that Sema keeps references of.
502 
503  /// \brief Record code for weak undeclared identifiers.
505 
506  /// \brief Record code for pending implicit instantiations.
508 
509  // ID 27 used to be for a list of replacement decls.
510 
511  /// \brief Record code for an update to a decl context's lookup table.
512  ///
513  /// In practice, this should only be used for the TU and namespaces.
515 
516  /// \brief Record for offsets of DECL_UPDATES records for declarations
517  /// that were modified after being deserialized and need updates.
519 
520  // ID 30 used to be a decl update record. These are now in the DECLTYPES
521  // block.
522 
523  // ID 31 used to be a list of offsets to DECL_CXX_BASE_SPECIFIERS records.
524 
525  // ID 32 used to be the code for \#pragma diagnostic mappings.
526 
527  /// \brief Record code for special CUDA declarations.
529 
530  /// \brief Record code for header search information.
532 
533  /// \brief Record code for floating point \#pragma options.
535 
536  /// \brief Record code for enabled OpenCL extensions.
538 
539  /// \brief The list of delegating constructor declarations.
541 
542  /// \brief Record code for the set of known namespaces, which are used
543  /// for typo correction.
545 
546  /// \brief Record code for the remapping information used to relate
547  /// loaded modules to the various offsets and IDs(e.g., source location
548  /// offests, declaration and type IDs) that are used in that module to
549  /// refer to other modules.
551 
552  /// \brief Record code for the source manager line table information,
553  /// which stores information about \#line directives.
555 
556  /// \brief Record code for map of Objective-C class definition IDs to the
557  /// ObjC categories in a module that are attached to that class.
559 
560  /// \brief Record code for a file sorted array of DeclIDs in a module.
562 
563  /// \brief Record code for an array of all of the (sub)modules that were
564  /// imported by the AST file.
566 
567  // ID 44 used to be a table of merged canonical declarations.
568  // ID 45 used to be a list of declaration IDs of local redeclarations.
569 
570  /// \brief Record code for the array of Objective-C categories (including
571  /// extensions).
572  ///
573  /// This array can only be interpreted properly using the Objective-C
574  /// categories map.
576 
577  /// \brief Record code for the table of offsets of each macro ID.
578  ///
579  /// The offset table contains offsets into the blob stored in
580  /// the preprocessor block. Each offset points to the corresponding
581  /// macro definition.
583 
584  /// \brief A list of "interesting" identifiers. Only used in C++ (where we
585  /// don't normally do lookups into the serialized identifier table). These
586  /// are eagerly deserialized.
588 
589  /// \brief Record code for undefined but used functions and variables that
590  /// need a definition in this TU.
592 
593  /// \brief Record code for late parsed template functions.
595 
596  /// \brief Record code for \#pragma optimize options.
598 
599  /// \brief Record code for potentially unused local typedef names.
601 
602  // ID 53 used to be a table of constructor initializer records.
603 
604  /// \brief Delete expressions that will be analyzed later.
606 
607  /// \brief Record code for \#pragma ms_struct options.
609 
610  /// \brief Record code for \#pragma ms_struct options.
612 
613  /// \brief Number of unmatched #pragma clang cuda_force_host_device begin
614  /// directives we've seen.
616 
617  /// \brief Record code for types associated with OpenCL extensions.
619 
620  /// \brief Record code for declarations associated with OpenCL extensions.
622 
624 
625  /// \brief Record code for \#pragma pack options.
627 
628  /// \brief The stack of open #ifs/#ifdefs recorded in a preamble.
630  };
631 
632  /// \brief Record types used within a source manager block.
634  /// \brief Describes a source location entry (SLocEntry) for a
635  /// file.
637 
638  /// \brief Describes a source location entry (SLocEntry) for a
639  /// buffer.
641 
642  /// \brief Describes a blob that contains the data for a buffer
643  /// entry. This kind of record always directly follows a
644  /// SM_SLOC_BUFFER_ENTRY record or a SM_SLOC_FILE_ENTRY with an
645  /// overridden buffer.
647 
648  /// \brief Describes a zlib-compressed blob that contains the data for
649  /// a buffer entry.
651 
652  /// \brief Describes a source location entry (SLocEntry) for a
653  /// macro expansion.
655  };
656 
657  /// \brief Record types used within a preprocessor block.
659  // The macros in the PP section are a PP_MACRO_* instance followed by a
660  // list of PP_TOKEN instances for each token in the definition.
661 
662  /// \brief An object-like macro definition.
663  /// [PP_MACRO_OBJECT_LIKE, IdentInfoID, SLoc, IsUsed]
665 
666  /// \brief A function-like macro definition.
667  /// [PP_MACRO_FUNCTION_LIKE, <ObjectLikeStuff>, IsC99Varargs,
668  /// IsGNUVarars, NumArgs, ArgIdentInfoID* ]
670 
671  /// \brief Describes one token.
672  /// [PP_TOKEN, SLoc, Length, IdentInfoID, Kind, Flags]
673  PP_TOKEN = 3,
674 
675  /// \brief The macro directives history for a particular identifier.
677 
678  /// \brief A macro directive exported by a module.
679  /// [PP_MODULE_MACRO, SubmoduleID, MacroID, (Overridden SubmoduleID)*]
681  };
682 
683  /// \brief Record types used within a preprocessor detail block.
685  /// \brief Describes a macro expansion within the preprocessing record.
687 
688  /// \brief Describes a macro definition within the preprocessing record.
690 
691  /// \brief Describes an inclusion directive within the preprocessing
692  /// record.
694  };
695 
696  /// \brief Record types used within a submodule description block.
698  /// \brief Metadata for submodules as a whole.
700 
701  /// \brief Defines the major attributes of a submodule, including its
702  /// name and parent.
704 
705  /// \brief Specifies the umbrella header used to create this module,
706  /// if any.
708 
709  /// \brief Specifies a header that falls into this (sub)module.
711 
712  /// \brief Specifies a top-level header that falls into this (sub)module.
714 
715  /// \brief Specifies an umbrella directory.
717 
718  /// \brief Specifies the submodules that are imported by this
719  /// submodule.
721 
722  /// \brief Specifies the submodules that are re-exported from this
723  /// submodule.
725 
726  /// \brief Specifies a required feature.
728 
729  /// \brief Specifies a header that has been explicitly excluded
730  /// from this submodule.
732 
733  /// \brief Specifies a library or framework to link against.
735 
736  /// \brief Specifies a configuration macro for this module.
738 
739  /// \brief Specifies a conflict with another module.
741 
742  /// \brief Specifies a header that is private to this submodule.
744 
745  /// \brief Specifies a header that is part of the module but must be
746  /// textually included.
748 
749  /// \brief Specifies a header that is private to this submodule but
750  /// must be textually included.
752 
753  /// \brief Specifies some declarations with initializers that must be
754  /// emitted to initialize the module.
756 
757  /// \brief Specifies the name of the module that will eventually
758  /// re-export the entities in this module.
760  };
761 
762  /// \brief Record types used within a comments block.
765  };
766 
767  /// \defgroup ASTAST AST file AST constants
768  ///
769  /// The constants in this group describe various components of the
770  /// abstract syntax tree within an AST file.
771  ///
772  /// @{
773 
774  /// \brief Predefined type IDs.
775  ///
776  /// These type IDs correspond to predefined types in the AST
777  /// context, such as built-in types (int) and special place-holder
778  /// types (the <overload> and <dependent> type markers). Such
779  /// types are never actually serialized, since they will be built
780  /// by the AST context when it is created.
782  /// \brief The NULL type.
784 
785  /// \brief The void type.
787 
788  /// \brief The 'bool' or '_Bool' type.
790 
791  /// \brief The 'char' type, when it is unsigned.
793 
794  /// \brief The 'unsigned char' type.
796 
797  /// \brief The 'unsigned short' type.
799 
800  /// \brief The 'unsigned int' type.
802 
803  /// \brief The 'unsigned long' type.
805 
806  /// \brief The 'unsigned long long' type.
808 
809  /// \brief The 'char' type, when it is signed.
811 
812  /// \brief The 'signed char' type.
814 
815  /// \brief The C++ 'wchar_t' type.
817 
818  /// \brief The (signed) 'short' type.
820 
821  /// \brief The (signed) 'int' type.
823 
824  /// \brief The (signed) 'long' type.
826 
827  /// \brief The (signed) 'long long' type.
829 
830  /// \brief The 'float' type.
832 
833  /// \brief The 'double' type.
835 
836  /// \brief The 'long double' type.
838 
839  /// \brief The placeholder type for overloaded function sets.
841 
842  /// \brief The placeholder type for dependent types.
844 
845  /// \brief The '__uint128_t' type.
847 
848  /// \brief The '__int128_t' type.
850 
851  /// \brief The type of 'nullptr'.
853 
854  /// \brief The C++ 'char16_t' type.
856 
857  /// \brief The C++ 'char32_t' type.
859 
860  /// \brief The ObjC 'id' type.
862 
863  /// \brief The ObjC 'Class' type.
865 
866  /// \brief The ObjC 'SEL' type.
868 
869  /// \brief The 'unknown any' placeholder type.
871 
872  /// \brief The placeholder type for bound member functions.
874 
875  /// \brief The "auto" deduction type.
877 
878  /// \brief The "auto &&" deduction type.
880 
881  /// \brief The OpenCL 'half' / ARM NEON __fp16 type.
883 
884  /// \brief ARC's unbridged-cast placeholder type.
886 
887  /// \brief The pseudo-object placeholder type.
889 
890  /// \brief The placeholder type for builtin functions.
892 
893  /// \brief OpenCL event type.
895 
896  /// \brief OpenCL clk event type.
898 
899  /// \brief OpenCL sampler type.
901 
902  /// \brief OpenCL queue type.
904 
905  /// \brief OpenCL reserve_id type.
907 
908  /// \brief The placeholder type for OpenMP array section.
910 
911  /// \brief The '__float128' type
913 
914  /// \brief The '_Float16' type
916 
917  /// \brief OpenCL image types with auto numeration
918 #define IMAGE_TYPE(ImgType, Id, SingletonId, Access, Suffix) \
919  PREDEF_TYPE_##Id##_ID,
920 #include "clang/Basic/OpenCLImageTypes.def"
921  };
922 
923  /// \brief The number of predefined type IDs that are reserved for
924  /// the PREDEF_TYPE_* constants.
925  ///
926  /// Type IDs for non-predefined types will start at
927  /// NUM_PREDEF_TYPE_IDs.
928  const unsigned NUM_PREDEF_TYPE_IDS = 100;
929 
930  /// \brief Record codes for each kind of type.
931  ///
932  /// These constants describe the type records that can occur within a
933  /// block identified by DECLTYPES_BLOCK_ID in the AST file. Each
934  /// constant describes a record for a specific type class in the
935  /// AST. Note that DeclCode values share this code space.
936  enum TypeCode {
937  /// \brief An ExtQualType record.
939 
940  /// \brief A ComplexType record.
942 
943  /// \brief A PointerType record.
945 
946  /// \brief A BlockPointerType record.
948 
949  /// \brief An LValueReferenceType record.
951 
952  /// \brief An RValueReferenceType record.
954 
955  /// \brief A MemberPointerType record.
957 
958  /// \brief A ConstantArrayType record.
960 
961  /// \brief An IncompleteArrayType record.
963 
964  /// \brief A VariableArrayType record.
966 
967  /// \brief A VectorType record.
969 
970  /// \brief An ExtVectorType record.
972 
973  /// \brief A FunctionNoProtoType record.
975 
976  /// \brief A FunctionProtoType record.
978 
979  /// \brief A TypedefType record.
981 
982  /// \brief A TypeOfExprType record.
984 
985  /// \brief A TypeOfType record.
987 
988  /// \brief A RecordType record.
990 
991  /// \brief An EnumType record.
992  TYPE_ENUM = 20,
993 
994  /// \brief An ObjCInterfaceType record.
996 
997  /// \brief An ObjCObjectPointerType record.
999 
1000  /// \brief a DecltypeType record.
1002 
1003  /// \brief An ElaboratedType record.
1005 
1006  /// \brief A SubstTemplateTypeParmType record.
1008 
1009  /// \brief An UnresolvedUsingType record.
1011 
1012  /// \brief An InjectedClassNameType record.
1014 
1015  /// \brief An ObjCObjectType record.
1017 
1018  /// \brief An TemplateTypeParmType record.
1020 
1021  /// \brief An TemplateSpecializationType record.
1023 
1024  /// \brief A DependentNameType record.
1026 
1027  /// \brief A DependentTemplateSpecializationType record.
1029 
1030  /// \brief A DependentSizedArrayType record.
1032 
1033  /// \brief A ParenType record.
1035 
1036  /// \brief A PackExpansionType record.
1038 
1039  /// \brief An AttributedType record.
1041 
1042  /// \brief A SubstTemplateTypeParmPackType record.
1044 
1045  /// \brief A AutoType record.
1047 
1048  /// \brief A UnaryTransformType record.
1050 
1051  /// \brief An AtomicType record.
1053 
1054  /// \brief A DecayedType record.
1056 
1057  /// \brief An AdjustedType record.
1059 
1060  /// \brief A PipeType record.
1062 
1063  /// \brief An ObjCTypeParamType record.
1065 
1066  /// \brief A DeducedTemplateSpecializationType record.
1068 
1069  /// \brief A DependentSizedExtVectorType record.
1071 
1072  /// \brief A DependentAddressSpaceType record.
1074  };
1075 
1076  /// \brief The type IDs for special types constructed by semantic
1077  /// analysis.
1078  ///
1079  /// The constants in this enumeration are indices into the
1080  /// SPECIAL_TYPES record.
1082  /// \brief CFConstantString type
1084 
1085  /// \brief C FILE typedef type
1087 
1088  /// \brief C jmp_buf typedef type
1090 
1091  /// \brief C sigjmp_buf typedef type
1093 
1094  /// \brief Objective-C "id" redefinition type
1096 
1097  /// \brief Objective-C "Class" redefinition type
1099 
1100  /// \brief Objective-C "SEL" redefinition type
1102 
1103  /// \brief C ucontext_t typedef type
1105  };
1106 
1107  /// \brief The number of special type IDs.
1108  const unsigned NumSpecialTypeIDs = 8;
1109 
1110  /// \brief Predefined declaration IDs.
1111  ///
1112  /// These declaration IDs correspond to predefined declarations in the AST
1113  /// context, such as the NULL declaration ID. Such declarations are never
1114  /// actually serialized, since they will be built by the AST context when
1115  /// it is created.
1117  /// \brief The NULL declaration.
1119 
1120  /// \brief The translation unit.
1122 
1123  /// \brief The Objective-C 'id' type.
1125 
1126  /// \brief The Objective-C 'SEL' type.
1128 
1129  /// \brief The Objective-C 'Class' type.
1131 
1132  /// \brief The Objective-C 'Protocol' type.
1134 
1135  /// \brief The signed 128-bit integer type.
1137 
1138  /// \brief The unsigned 128-bit integer type.
1140 
1141  /// \brief The internal 'instancetype' typedef.
1143 
1144  /// \brief The internal '__builtin_va_list' typedef.
1146 
1147  /// \brief The internal '__va_list_tag' struct, if any.
1149 
1150  /// \brief The internal '__builtin_ms_va_list' typedef.
1152 
1153  /// \brief The extern "C" context.
1155 
1156  /// \brief The internal '__make_integer_seq' template.
1158 
1159  /// \brief The internal '__NSConstantString' typedef.
1161 
1162  /// \brief The internal '__NSConstantString' tag type.
1164 
1165  /// \brief The internal '__type_pack_element' template.
1167  };
1168 
1169  /// \brief The number of declaration IDs that are predefined.
1170  ///
1171  /// For more information about predefined declarations, see the
1172  /// \c PredefinedDeclIDs type and the PREDEF_DECL_*_ID constants.
1173  const unsigned int NUM_PREDEF_DECL_IDS = 17;
1174 
1175  /// \brief Record of updates for a declaration that was modified after
1176  /// being deserialized. This can occur within DECLTYPES_BLOCK_ID.
1177  const unsigned int DECL_UPDATES = 49;
1178 
1179  /// \brief Record code for a list of local redeclarations of a declaration.
1180  /// This can occur within DECLTYPES_BLOCK_ID.
1181  const unsigned int LOCAL_REDECLARATIONS = 50;
1182 
1183  /// \brief Record codes for each kind of declaration.
1184  ///
1185  /// These constants describe the declaration records that can occur within
1186  /// a declarations block (identified by DECLTYPES_BLOCK_ID). Each
1187  /// constant describes a record for a specific declaration class
1188  /// in the AST. Note that TypeCode values share this code space.
1189  enum DeclCode {
1190  /// \brief A TypedefDecl record.
1192  /// \brief A TypeAliasDecl record.
1193 
1195 
1196  /// \brief An EnumDecl record.
1198 
1199  /// \brief A RecordDecl record.
1201 
1202  /// \brief An EnumConstantDecl record.
1204 
1205  /// \brief A FunctionDecl record.
1207 
1208  /// \brief A ObjCMethodDecl record.
1210 
1211  /// \brief A ObjCInterfaceDecl record.
1213 
1214  /// \brief A ObjCProtocolDecl record.
1216 
1217  /// \brief A ObjCIvarDecl record.
1219 
1220  /// \brief A ObjCAtDefsFieldDecl record.
1222 
1223  /// \brief A ObjCCategoryDecl record.
1225 
1226  /// \brief A ObjCCategoryImplDecl record.
1228 
1229  /// \brief A ObjCImplementationDecl record.
1231 
1232  /// \brief A ObjCCompatibleAliasDecl record.
1234 
1235  /// \brief A ObjCPropertyDecl record.
1237 
1238  /// \brief A ObjCPropertyImplDecl record.
1240 
1241  /// \brief A FieldDecl record.
1243 
1244  /// \brief A MSPropertyDecl record.
1246 
1247  /// \brief A VarDecl record.
1249 
1250  /// \brief An ImplicitParamDecl record.
1252 
1253  /// \brief A ParmVarDecl record.
1255 
1256  /// \brief A DecompositionDecl record.
1258 
1259  /// \brief A BindingDecl record.
1261 
1262  /// \brief A FileScopeAsmDecl record.
1264 
1265  /// \brief A BlockDecl record.
1267 
1268  /// \brief A CapturedDecl record.
1270 
1271  /// \brief A record that stores the set of declarations that are
1272  /// lexically stored within a given DeclContext.
1273  ///
1274  /// The record itself is a blob that is an array of declaration IDs,
1275  /// in the order in which those declarations were added to the
1276  /// declaration context. This data is used when iterating over
1277  /// the contents of a DeclContext, e.g., via
1278  /// DeclContext::decls_begin() and DeclContext::decls_end().
1280 
1281  /// \brief A record that stores the set of declarations that are
1282  /// visible from a given DeclContext.
1283  ///
1284  /// The record itself stores a set of mappings, each of which
1285  /// associates a declaration name with one or more declaration
1286  /// IDs. This data is used when performing qualified name lookup
1287  /// into a DeclContext via DeclContext::lookup.
1289 
1290  /// \brief A LabelDecl record.
1292 
1293  /// \brief A NamespaceDecl record.
1295 
1296  /// \brief A NamespaceAliasDecl record.
1298 
1299  /// \brief A UsingDecl record.
1301 
1302  /// \brief A UsingPackDecl record.
1304 
1305  /// \brief A UsingShadowDecl record.
1307 
1308  /// \brief A ConstructorUsingShadowDecl record.
1310 
1311  /// \brief A UsingDirecitveDecl record.
1313 
1314  /// \brief An UnresolvedUsingValueDecl record.
1316 
1317  /// \brief An UnresolvedUsingTypenameDecl record.
1319 
1320  /// \brief A LinkageSpecDecl record.
1322 
1323  /// \brief An ExportDecl record.
1325 
1326  /// \brief A CXXRecordDecl record.
1328 
1329  /// \brief A CXXDeductionGuideDecl record.
1331 
1332  /// \brief A CXXMethodDecl record.
1334 
1335  /// \brief A CXXConstructorDecl record.
1337 
1338  /// \brief A CXXConstructorDecl record for an inherited constructor.
1340 
1341  /// \brief A CXXDestructorDecl record.
1343 
1344  /// \brief A CXXConversionDecl record.
1346 
1347  /// \brief An AccessSpecDecl record.
1349 
1350  /// \brief A FriendDecl record.
1352 
1353  /// \brief A FriendTemplateDecl record.
1355 
1356  /// \brief A ClassTemplateDecl record.
1358 
1359  /// \brief A ClassTemplateSpecializationDecl record.
1361 
1362  /// \brief A ClassTemplatePartialSpecializationDecl record.
1364 
1365  /// \brief A VarTemplateDecl record.
1367 
1368  /// \brief A VarTemplateSpecializationDecl record.
1370 
1371  /// \brief A VarTemplatePartialSpecializationDecl record.
1373 
1374  /// \brief A FunctionTemplateDecl record.
1376 
1377  /// \brief A TemplateTypeParmDecl record.
1379 
1380  /// \brief A NonTypeTemplateParmDecl record.
1382 
1383  /// \brief A TemplateTemplateParmDecl record.
1385 
1386  /// \brief A TypeAliasTemplateDecl record.
1388 
1389  /// \brief A StaticAssertDecl record.
1391 
1392  /// \brief A record containing CXXBaseSpecifiers.
1394 
1395  /// \brief A record containing CXXCtorInitializers.
1397 
1398  /// \brief A IndirectFieldDecl record.
1400 
1401  /// \brief A NonTypeTemplateParmDecl record that stores an expanded
1402  /// non-type template parameter pack.
1404 
1405  /// \brief A TemplateTemplateParmDecl record that stores an expanded
1406  /// template template parameter pack.
1408 
1409  /// \brief A ClassScopeFunctionSpecializationDecl record a class scope
1410  /// function specialization. (Microsoft extension).
1412 
1413  /// \brief An ImportDecl recording a module import.
1415 
1416  /// \brief An OMPThreadPrivateDecl record.
1418 
1419  /// \brief An EmptyDecl record.
1421 
1422  /// \brief An ObjCTypeParamDecl record.
1424 
1425  /// \brief An OMPCapturedExprDecl record.
1427 
1428  /// \brief A PragmaCommentDecl record.
1430 
1431  /// \brief A PragmaDetectMismatchDecl record.
1433 
1434  /// \brief An OMPDeclareReductionDecl record.
1436  };
1437 
1438  /// \brief Record codes for each kind of statement or expression.
1439  ///
1440  /// These constants describe the records that describe statements
1441  /// or expressions. These records occur within type and declarations
1442  /// block, so they begin with record values of 128. Each constant
1443  /// describes a record for a specific statement or expression class in the
1444  /// AST.
1445  enum StmtCode {
1446  /// \brief A marker record that indicates that we are at the end
1447  /// of an expression.
1448  STMT_STOP = 128,
1449 
1450  /// \brief A NULL expression.
1452 
1453  /// \brief A reference to a previously [de]serialized Stmt record.
1455 
1456  /// \brief A NullStmt record.
1458 
1459  /// \brief A CompoundStmt record.
1461 
1462  /// \brief A CaseStmt record.
1464 
1465  /// \brief A DefaultStmt record.
1467 
1468  /// \brief A LabelStmt record.
1470 
1471  /// \brief An AttributedStmt record.
1473 
1474  /// \brief An IfStmt record.
1476 
1477  /// \brief A SwitchStmt record.
1479 
1480  /// \brief A WhileStmt record.
1482 
1483  /// \brief A DoStmt record.
1485 
1486  /// \brief A ForStmt record.
1488 
1489  /// \brief A GotoStmt record.
1491 
1492  /// \brief An IndirectGotoStmt record.
1494 
1495  /// \brief A ContinueStmt record.
1497 
1498  /// \brief A BreakStmt record.
1500 
1501  /// \brief A ReturnStmt record.
1503 
1504  /// \brief A DeclStmt record.
1506 
1507  /// \brief A CapturedStmt record.
1509 
1510  /// \brief A GCC-style AsmStmt record.
1512 
1513  /// \brief A MS-style AsmStmt record.
1515 
1516  /// \brief A PredefinedExpr record.
1518 
1519  /// \brief A DeclRefExpr record.
1521 
1522  /// \brief An IntegerLiteral record.
1524 
1525  /// \brief A FloatingLiteral record.
1527 
1528  /// \brief An ImaginaryLiteral record.
1530 
1531  /// \brief A StringLiteral record.
1533 
1534  /// \brief A CharacterLiteral record.
1536 
1537  /// \brief A ParenExpr record.
1539 
1540  /// \brief A ParenListExpr record.
1542 
1543  /// \brief A UnaryOperator record.
1545 
1546  /// \brief An OffsetOfExpr record.
1548 
1549  /// \brief A SizefAlignOfExpr record.
1551 
1552  /// \brief An ArraySubscriptExpr record.
1554 
1555  /// \brief A CallExpr record.
1557 
1558  /// \brief A MemberExpr record.
1560 
1561  /// \brief A BinaryOperator record.
1563 
1564  /// \brief A CompoundAssignOperator record.
1566 
1567  /// \brief A ConditionOperator record.
1569 
1570  /// \brief An ImplicitCastExpr record.
1572 
1573  /// \brief A CStyleCastExpr record.
1575 
1576  /// \brief A CompoundLiteralExpr record.
1578 
1579  /// \brief An ExtVectorElementExpr record.
1581 
1582  /// \brief An InitListExpr record.
1584 
1585  /// \brief A DesignatedInitExpr record.
1587 
1588  /// \brief A DesignatedInitUpdateExpr record.
1590 
1591  /// \brief An NoInitExpr record.
1593 
1594  /// \brief An ArrayInitLoopExpr record.
1596 
1597  /// \brief An ArrayInitIndexExpr record.
1599 
1600  /// \brief An ImplicitValueInitExpr record.
1602 
1603  /// \brief A VAArgExpr record.
1605 
1606  /// \brief An AddrLabelExpr record.
1608 
1609  /// \brief A StmtExpr record.
1611 
1612  /// \brief A ChooseExpr record.
1614 
1615  /// \brief A GNUNullExpr record.
1617 
1618  /// \brief A ShuffleVectorExpr record.
1620 
1621  /// \brief A ConvertVectorExpr record.
1623 
1624  /// \brief BlockExpr
1626 
1627  /// \brief A GenericSelectionExpr record.
1629 
1630  /// \brief A PseudoObjectExpr record.
1632 
1633  /// \brief An AtomicExpr record.
1635 
1636  // Objective-C
1637 
1638  /// \brief An ObjCStringLiteral record.
1640 
1644 
1645  /// \brief An ObjCEncodeExpr record.
1647 
1648  /// \brief An ObjCSelectorExpr record.
1650 
1651  /// \brief An ObjCProtocolExpr record.
1653 
1654  /// \brief An ObjCIvarRefExpr record.
1656 
1657  /// \brief An ObjCPropertyRefExpr record.
1659 
1660  /// \brief An ObjCSubscriptRefExpr record.
1662 
1663  /// \brief UNUSED
1665 
1666  /// \brief An ObjCMessageExpr record.
1668 
1669  /// \brief An ObjCIsa Expr record.
1671 
1672  /// \brief An ObjCIndirectCopyRestoreExpr record.
1674 
1675  /// \brief An ObjCForCollectionStmt record.
1677 
1678  /// \brief An ObjCAtCatchStmt record.
1680 
1681  /// \brief An ObjCAtFinallyStmt record.
1683 
1684  /// \brief An ObjCAtTryStmt record.
1686 
1687  /// \brief An ObjCAtSynchronizedStmt record.
1689 
1690  /// \brief An ObjCAtThrowStmt record.
1692 
1693  /// \brief An ObjCAutoreleasePoolStmt record.
1695 
1696  /// \brief An ObjCBoolLiteralExpr record.
1698 
1699  /// \brief An ObjCAvailabilityCheckExpr record.
1701 
1702  // C++
1703 
1704  /// \brief A CXXCatchStmt record.
1706 
1707  /// \brief A CXXTryStmt record.
1709  /// \brief A CXXForRangeStmt record.
1710 
1712 
1713  /// \brief A CXXOperatorCallExpr record.
1715 
1716  /// \brief A CXXMemberCallExpr record.
1718 
1719  /// \brief A CXXConstructExpr record.
1721 
1722  /// \brief A CXXInheritedCtorInitExpr record.
1724 
1725  /// \brief A CXXTemporaryObjectExpr record.
1727 
1728  /// \brief A CXXStaticCastExpr record.
1730 
1731  /// \brief A CXXDynamicCastExpr record.
1733 
1734  /// \brief A CXXReinterpretCastExpr record.
1736 
1737  /// \brief A CXXConstCastExpr record.
1739 
1740  /// \brief A CXXFunctionalCastExpr record.
1742 
1743  /// \brief A UserDefinedLiteral record.
1745 
1746  /// \brief A CXXStdInitializerListExpr record.
1748 
1749  /// \brief A CXXBoolLiteralExpr record.
1751 
1752  EXPR_CXX_NULL_PTR_LITERAL, // CXXNullPtrLiteralExpr
1753  EXPR_CXX_TYPEID_EXPR, // CXXTypeidExpr (of expr).
1754  EXPR_CXX_TYPEID_TYPE, // CXXTypeidExpr (of type).
1755  EXPR_CXX_THIS, // CXXThisExpr
1756  EXPR_CXX_THROW, // CXXThrowExpr
1757  EXPR_CXX_DEFAULT_ARG, // CXXDefaultArgExpr
1758  EXPR_CXX_DEFAULT_INIT, // CXXDefaultInitExpr
1759  EXPR_CXX_BIND_TEMPORARY, // CXXBindTemporaryExpr
1760 
1761  EXPR_CXX_SCALAR_VALUE_INIT, // CXXScalarValueInitExpr
1762  EXPR_CXX_NEW, // CXXNewExpr
1763  EXPR_CXX_DELETE, // CXXDeleteExpr
1764  EXPR_CXX_PSEUDO_DESTRUCTOR, // CXXPseudoDestructorExpr
1765 
1766  EXPR_EXPR_WITH_CLEANUPS, // ExprWithCleanups
1767 
1768  EXPR_CXX_DEPENDENT_SCOPE_MEMBER, // CXXDependentScopeMemberExpr
1769  EXPR_CXX_DEPENDENT_SCOPE_DECL_REF, // DependentScopeDeclRefExpr
1770  EXPR_CXX_UNRESOLVED_CONSTRUCT, // CXXUnresolvedConstructExpr
1771  EXPR_CXX_UNRESOLVED_MEMBER, // UnresolvedMemberExpr
1772  EXPR_CXX_UNRESOLVED_LOOKUP, // UnresolvedLookupExpr
1773 
1774  EXPR_CXX_EXPRESSION_TRAIT, // ExpressionTraitExpr
1775  EXPR_CXX_NOEXCEPT, // CXXNoexceptExpr
1776 
1777  EXPR_OPAQUE_VALUE, // OpaqueValueExpr
1778  EXPR_BINARY_CONDITIONAL_OPERATOR, // BinaryConditionalOperator
1779  EXPR_TYPE_TRAIT, // TypeTraitExpr
1780  EXPR_ARRAY_TYPE_TRAIT, // ArrayTypeTraitIntExpr
1781 
1782  EXPR_PACK_EXPANSION, // PackExpansionExpr
1783  EXPR_SIZEOF_PACK, // SizeOfPackExpr
1784  EXPR_SUBST_NON_TYPE_TEMPLATE_PARM, // SubstNonTypeTemplateParmExpr
1785  EXPR_SUBST_NON_TYPE_TEMPLATE_PARM_PACK,// SubstNonTypeTemplateParmPackExpr
1786  EXPR_FUNCTION_PARM_PACK, // FunctionParmPackExpr
1787  EXPR_MATERIALIZE_TEMPORARY, // MaterializeTemporaryExpr
1788  EXPR_CXX_FOLD, // CXXFoldExpr
1789 
1790  // CUDA
1791  EXPR_CUDA_KERNEL_CALL, // CUDAKernelCallExpr
1792 
1793  // OpenCL
1794  EXPR_ASTYPE, // AsTypeExpr
1795 
1796  // Microsoft
1797  EXPR_CXX_PROPERTY_REF_EXPR, // MSPropertyRefExpr
1798  EXPR_CXX_PROPERTY_SUBSCRIPT_EXPR, // MSPropertySubscriptExpr
1799  EXPR_CXX_UUIDOF_EXPR, // CXXUuidofExpr (of expr).
1800  EXPR_CXX_UUIDOF_TYPE, // CXXUuidofExpr (of type).
1801  STMT_SEH_LEAVE, // SEHLeaveStmt
1802  STMT_SEH_EXCEPT, // SEHExceptStmt
1803  STMT_SEH_FINALLY, // SEHFinallyStmt
1804  STMT_SEH_TRY, // SEHTryStmt
1805 
1806  // OpenMP directives
1855 
1856  // ARC
1857  EXPR_OBJC_BRIDGED_CAST, // ObjCBridgedCastExpr
1858 
1859  STMT_MS_DEPENDENT_EXISTS, // MSDependentExistsStmt
1860  EXPR_LAMBDA, // LambdaExpr
1866  };
1867 
1868  /// \brief The kinds of designators that can occur in a
1869  /// DesignatedInitExpr.
1871  /// \brief Field designator where only the field name is known.
1873 
1874  /// \brief Field designator where the field has been resolved to
1875  /// a declaration.
1877 
1878  /// \brief Array designator.
1880 
1881  /// \brief GNU array range designator.
1883  };
1884 
1885  /// \brief The different kinds of data that can occur in a
1886  /// CtorInitializer.
1892  };
1893 
1894  /// \brief Describes the redeclarations of a declaration.
1896  // The ID of the first declaration
1898 
1899  // Offset into the array of redeclaration chains.
1900  unsigned Offset;
1901 
1903  const LocalRedeclarationsInfo &Y) {
1904  return X.FirstID < Y.FirstID;
1905  }
1906 
1908  const LocalRedeclarationsInfo &Y) {
1909  return X.FirstID > Y.FirstID;
1910  }
1911 
1913  const LocalRedeclarationsInfo &Y) {
1914  return X.FirstID <= Y.FirstID;
1915  }
1916 
1918  const LocalRedeclarationsInfo &Y) {
1919  return X.FirstID >= Y.FirstID;
1920  }
1921  };
1922 
1923  /// \brief Describes the categories of an Objective-C class.
1925  // The ID of the definition
1927 
1928  // Offset into the array of category lists.
1929  unsigned Offset;
1930 
1931  friend bool operator<(const ObjCCategoriesInfo &X,
1932  const ObjCCategoriesInfo &Y) {
1933  return X.DefinitionID < Y.DefinitionID;
1934  }
1935 
1936  friend bool operator>(const ObjCCategoriesInfo &X,
1937  const ObjCCategoriesInfo &Y) {
1938  return X.DefinitionID > Y.DefinitionID;
1939  }
1940 
1941  friend bool operator<=(const ObjCCategoriesInfo &X,
1942  const ObjCCategoriesInfo &Y) {
1943  return X.DefinitionID <= Y.DefinitionID;
1944  }
1945 
1946  friend bool operator>=(const ObjCCategoriesInfo &X,
1947  const ObjCCategoriesInfo &Y) {
1948  return X.DefinitionID >= Y.DefinitionID;
1949  }
1950  };
1951 
1952  /// \brief A key used when looking up entities by \ref DeclarationName.
1953  ///
1954  /// Different \ref DeclarationNames are mapped to different keys, but the
1955  /// same key can occasionally represent multiple names (for names that
1956  /// contain types, in particular).
1958  using NameKind = unsigned;
1959 
1960  NameKind Kind = 0;
1961  uint64_t Data = 0;
1962 
1963  public:
1964  DeclarationNameKey() = default;
1966  DeclarationNameKey(NameKind Kind, uint64_t Data)
1967  : Kind(Kind), Data(Data) {}
1968 
1969  NameKind getKind() const { return Kind; }
1970 
1972  assert(Kind == DeclarationName::Identifier ||
1975  return (IdentifierInfo *)Data;
1976  }
1977 
1979  assert(Kind == DeclarationName::ObjCZeroArgSelector ||
1982  return Selector(Data);
1983  }
1984 
1986  assert(Kind == DeclarationName::CXXOperatorName);
1987  return (OverloadedOperatorKind)Data;
1988  }
1989 
1990  /// Compute a fingerprint of this key for use in on-disk hash table.
1991  unsigned getHash() const;
1992 
1993  friend bool operator==(const DeclarationNameKey &A,
1994  const DeclarationNameKey &B) {
1995  return A.Kind == B.Kind && A.Data == B.Data;
1996  }
1997  };
1998 
1999  /// @}
2000 
2001 } // namespace serialization
2002 } // namespace clang
2003 
2004 namespace llvm {
2005 
2006  template <> struct DenseMapInfo<clang::serialization::DeclarationNameKey> {
2009  }
2010 
2013  }
2014 
2015  static unsigned
2017  return Key.getHash();
2018  }
2019 
2022  return L == R;
2023  }
2024  };
2025 
2026 } // namespace llvm
2027 
2028 #endif // LLVM_CLANG_SERIALIZATION_ASTBITCODES_H
A PredefinedExpr record.
Definition: ASTBitCodes.h:1517
A FriendTemplateDecl record.
Definition: ASTBitCodes.h:1354
A CompoundLiteralExpr record.
Definition: ASTBitCodes.h:1577
A NonTypeTemplateParmDecl record.
Definition: ASTBitCodes.h:1381
The ObjC &#39;SEL&#39; type.
Definition: ASTBitCodes.h:867
DesignatorTypes
The kinds of designators that can occur in a DesignatedInitExpr.
Definition: ASTBitCodes.h:1870
Record code for the preprocessor options table.
Definition: ASTBitCodes.h:339
BlockIDs
Describes the various kinds of blocks that occur within an AST file.
Definition: ASTBitCodes.h:227
Source range/offset of a preprocessed entity.
Definition: ASTBitCodes.h:178
Record code for potentially unused local typedef names.
Definition: ASTBitCodes.h:600
Smart pointer class that efficiently represents Objective-C method names.
Record code for map of Objective-C class definition IDs to the ObjC categories in a module that are a...
Definition: ASTBitCodes.h:558
An IndirectGotoStmt record.
Definition: ASTBitCodes.h:1493
unsigned getRawEncoding() const
When a SourceLocation itself cannot be used, this returns an (opaque) 32-bit integer encoding for it...
A (possibly-)qualified type.
Definition: Type.h:653
A PointerType record.
Definition: ASTBitCodes.h:944
CtorInitializerType
The different kinds of data that can occur in a CtorInitializer.
Definition: ASTBitCodes.h:1887
The &#39;_Float16&#39; type.
Definition: ASTBitCodes.h:915
An AddrLabelExpr record.
Definition: ASTBitCodes.h:1607
The macro directives history for a particular identifier.
Definition: ASTBitCodes.h:676
The &#39;unsigned int&#39; type.
Definition: ASTBitCodes.h:801
The (signed) &#39;long long&#39; type.
Definition: ASTBitCodes.h:828
A CXXStaticCastExpr record.
Definition: ASTBitCodes.h:1729
ExtensionBlockRecordTypes
Record code for extension blocks.
Definition: ASTBitCodes.h:355
Record code for the source manager line table information, which stores information about #line direc...
Definition: ASTBitCodes.h:554
An AttributedStmt record.
Definition: ASTBitCodes.h:1472
A CXXReinterpretCastExpr record.
Definition: ASTBitCodes.h:1735
The &#39;bool&#39; or &#39;_Bool&#39; type.
Definition: ASTBitCodes.h:789
An OMPThreadPrivateDecl record.
Definition: ASTBitCodes.h:1417
DominatorTree GraphTraits specialization so the DominatorTree can be iterable by generic graph iterat...
Definition: Dominators.h:26
An ObjCBoolLiteralExpr record.
Definition: ASTBitCodes.h:1697
A structure for putting "fast"-unqualified QualTypes into a DenseMap.
Definition: ASTBitCodes.h:115
const unsigned NUM_PREDEF_TYPE_IDS
The number of predefined type IDs that are reserved for the PREDEF_TYPE_* constants.
Definition: ASTBitCodes.h:928
friend bool operator>(const LocalRedeclarationsInfo &X, const LocalRedeclarationsInfo &Y)
Definition: ASTBitCodes.h:1907
uint32_t GlobalMacroID
A global ID number that refers to a macro in an AST file.
Definition: ASTBitCodes.h:144
ControlRecordTypes
Record types that occur within the control block.
Definition: ASTBitCodes.h:282
C Language Family Type Representation.
The &#39;unknown any&#39; placeholder type.
Definition: ASTBitCodes.h:870
An OMPDeclareReductionDecl record.
Definition: ASTBitCodes.h:1435
An ImplicitValueInitExpr record.
Definition: ASTBitCodes.h:1601
SourceManagerRecordTypes
Record types used within a source manager block.
Definition: ASTBitCodes.h:633
const unsigned int NUM_PREDEF_SELECTOR_IDS
The number of predefined selector IDs.
Definition: ASTBitCodes.h:157
An ImplicitCastExpr record.
Definition: ASTBitCodes.h:1571
A VarTemplatePartialSpecializationDecl record.
Definition: ASTBitCodes.h:1372
unsigned Begin
Raw source location of beginning of range.
Definition: ASTBitCodes.h:180
Describes a source location entry (SLocEntry) for a macro expansion.
Definition: ASTBitCodes.h:654
An LValueReferenceType record.
Definition: ASTBitCodes.h:950
The placeholder type for builtin functions.
Definition: ASTBitCodes.h:891
A CXXOperatorCallExpr record.
Definition: ASTBitCodes.h:1714
Specifies the submodules that are imported by this submodule.
Definition: ASTBitCodes.h:720
A record that stores the set of declarations that are lexically stored within a given DeclContext...
Definition: ASTBitCodes.h:1279
Specifies an umbrella directory.
Definition: ASTBitCodes.h:716
A CXXTemporaryObjectExpr record.
Definition: ASTBitCodes.h:1726
A SubstTemplateTypeParmType record.
Definition: ASTBitCodes.h:1007
A ObjCPropertyDecl record.
Definition: ASTBitCodes.h:1236
Record code for enabled OpenCL extensions.
Definition: ASTBitCodes.h:537
Record code for the module build directory.
Definition: ASTBitCodes.h:315
An ElaboratedType record.
Definition: ASTBitCodes.h:1004
An UnresolvedUsingType record.
Definition: ASTBitCodes.h:1010
static clang::serialization::DeclarationNameKey getTombstoneKey()
Definition: ASTBitCodes.h:2011
An IncompleteArrayType record.
Definition: ASTBitCodes.h:962
The internal &#39;__type_pack_element&#39; template.
Definition: ASTBitCodes.h:1166
Specifies a header that is part of the module but must be textually included.
Definition: ASTBitCodes.h:747
ARC&#39;s unbridged-cast placeholder type.
Definition: ASTBitCodes.h:885
The &#39;__int128_t&#39; type.
Definition: ASTBitCodes.h:849
A ClassTemplateDecl record.
Definition: ASTBitCodes.h:1357
A PragmaDetectMismatchDecl record.
Definition: ASTBitCodes.h:1432
The C++ &#39;char32_t&#39; type.
Definition: ASTBitCodes.h:858
An UnresolvedUsingTypenameDecl record.
Definition: ASTBitCodes.h:1318
The internal &#39;__builtin_va_list&#39; typedef.
Definition: ASTBitCodes.h:1145
The stack of open #ifs/#ifdefs recorded in a preamble.
Definition: ASTBitCodes.h:629
Record code for #pragma pack options.
Definition: ASTBitCodes.h:626
A block with unhashed content.
Definition: ASTBitCodes.h:278
friend bool operator<(const ObjCCategoriesInfo &X, const ObjCCategoriesInfo &Y)
Definition: ASTBitCodes.h:1931
An OMPCapturedExprDecl record.
Definition: ASTBitCodes.h:1426
Record code for declarations associated with OpenCL extensions.
Definition: ASTBitCodes.h:621
A UsingShadowDecl record.
Definition: ASTBitCodes.h:1306
const unsigned int NUM_PREDEF_DECL_IDS
The number of declaration IDs that are predefined.
Definition: ASTBitCodes.h:1173
The value of the next COUNTER to dispense.
Definition: ASTBitCodes.h:462
A TemplateTemplateParmDecl record that stores an expanded template template parameter pack...
Definition: ASTBitCodes.h:1407
Specifies the umbrella header used to create this module, if any.
Definition: ASTBitCodes.h:707
Record code for header search information.
Definition: ASTBitCodes.h:531
Describes a source location entry (SLocEntry) for a buffer.
Definition: ASTBitCodes.h:640
A CXXConstructExpr record.
Definition: ASTBitCodes.h:1720
Record code for the target options table.
Definition: ASTBitCodes.h:330
A TemplateTemplateParmDecl record.
Definition: ASTBitCodes.h:1384
Record code for the array of eagerly deserialized decls.
Definition: ASTBitCodes.h:433
A ObjCInterfaceDecl record.
Definition: ASTBitCodes.h:1212
A ShuffleVectorExpr record.
Definition: ASTBitCodes.h:1619
The width of the "fast" qualifier mask.
Definition: Type.h:195
A CXXConstructorDecl record for an inherited constructor.
Definition: ASTBitCodes.h:1339
const unsigned VERSION_MAJOR
AST file major version number supported by this version of Clang.
Definition: ASTBitCodes.h:45
An OffsetOfExpr record.
Definition: ASTBitCodes.h:1547
One of these records is kept for each identifier that is lexed.
A macro directive exported by a module.
Definition: ASTBitCodes.h:680
An ObjCAtThrowStmt record.
Definition: ASTBitCodes.h:1691
Specifies a top-level header that falls into this (sub)module.
Definition: ASTBitCodes.h:713
The block containing comments.
Definition: ASTBitCodes.h:251
A DesignatedInitExpr record.
Definition: ASTBitCodes.h:1586
The Objective-C &#39;SEL&#39; type.
Definition: ASTBitCodes.h:1127
static bool isEqual(const clang::serialization::DeclarationNameKey &L, const clang::serialization::DeclarationNameKey &R)
Definition: ASTBitCodes.h:2020
The &#39;char&#39; type, when it is signed.
Definition: ASTBitCodes.h:810
The &#39;unsigned long&#39; type.
Definition: ASTBitCodes.h:804
Specifies a header that has been explicitly excluded from this submodule.
Definition: ASTBitCodes.h:731
static SourceLocation getFromRawEncoding(unsigned Encoding)
Turn a raw encoding of a SourceLocation object into a real SourceLocation.
SourceLocation getBegin() const
Definition: ASTBitCodes.h:192
SpecialTypeIDs
The type IDs for special types constructed by semantic analysis.
Definition: ASTBitCodes.h:1081
friend bool operator<=(const ObjCCategoriesInfo &X, const ObjCCategoriesInfo &Y)
Definition: ASTBitCodes.h:1941
Record code for the module map file that was used to build this AST file.
Definition: ASTBitCodes.h:312
An ExtVectorType record.
Definition: ASTBitCodes.h:971
Delete expressions that will be analyzed later.
Definition: ASTBitCodes.h:605
friend bool operator==(const DeclarationNameKey &A, const DeclarationNameKey &B)
Definition: ASTBitCodes.h:1993
An AttributedType record.
Definition: ASTBitCodes.h:1040
uint32_t MacroID
An ID number that refers to a macro in an AST file.
Definition: ASTBitCodes.h:141
An object-like macro definition.
Definition: ASTBitCodes.h:664
Describes one token.
Definition: ASTBitCodes.h:673
An AdjustedType record.
Definition: ASTBitCodes.h:1058
A IndirectFieldDecl record.
Definition: ASTBitCodes.h:1399
Record code for the set of ext_vector type names.
Definition: ASTBitCodes.h:477
uint32_t LocalMacroID
A local to a module ID number that refers to a macro in an AST file.
Definition: ASTBitCodes.h:148
Specifies the submodules that are re-exported from this submodule.
Definition: ASTBitCodes.h:724
The Objective-C &#39;id&#39; type.
Definition: ASTBitCodes.h:1124
An AccessSpecDecl record.
Definition: ASTBitCodes.h:1348
const unsigned NumSpecialTypeIDs
The number of special type IDs.
Definition: ASTBitCodes.h:1108
Describes a blob that contains the data for a buffer entry.
Definition: ASTBitCodes.h:646
Record code for the language options table.
Definition: ASTBitCodes.h:327
Specifies a conflict with another module.
Definition: ASTBitCodes.h:740
unsigned getHash() const
Compute a fingerprint of this key for use in on-disk hash table.
Definition: ASTReader.cpp:1040
The signed 128-bit integer type.
Definition: ASTBitCodes.h:1136
A ConstructorUsingShadowDecl record.
Definition: ASTBitCodes.h:1309
A UnaryTransformType record.
Definition: ASTBitCodes.h:1049
A reference to a previously [de]serialized Stmt record.
Definition: ASTBitCodes.h:1454
A UsingDirecitveDecl record.
Definition: ASTBitCodes.h:1312
An ObjCObjectType record.
Definition: ASTBitCodes.h:1016
A ConstantArrayType record.
Definition: ASTBitCodes.h:959
Record code for #pragma optimize options.
Definition: ASTBitCodes.h:597
uint32_t BitOffset
Offset in the AST file.
Definition: ASTBitCodes.h:186
A DecompositionDecl record.
Definition: ASTBitCodes.h:1257
Specifies a header that is private to this submodule but must be textually included.
Definition: ASTBitCodes.h:751
Record code for pending implicit instantiations.
Definition: ASTBitCodes.h:507
The internal &#39;__make_integer_seq&#39; template.
Definition: ASTBitCodes.h:1157
An ExtQualType record.
Definition: ASTBitCodes.h:938
Record code for floating point #pragma options.
Definition: ASTBitCodes.h:534
CommentRecordTypes
Record types used within a comments block.
Definition: ASTBitCodes.h:763
Record code for the set of known namespaces, which are used for typo correction.
Definition: ASTBitCodes.h:544
Record code for an array of all of the (sub)modules that were imported by the AST file...
Definition: ASTBitCodes.h:565
The first record ID allocated to the extensions themselves.
Definition: ASTBitCodes.h:360
The &#39;unsigned short&#39; type.
Definition: ASTBitCodes.h:798
A marker record that indicates that we are at the end of an expression.
Definition: ASTBitCodes.h:1448
A ClassTemplateSpecializationDecl record.
Definition: ASTBitCodes.h:1360
A BlockPointerType record.
Definition: ASTBitCodes.h:947
uint32_t getIndex() const
Definition: ASTBitCodes.h:96
A MemberPointerType record.
Definition: ASTBitCodes.h:956
void * getAsOpaquePtr() const
Definition: Type.h:699
A DependentSizedExtVectorType record.
Definition: ASTBitCodes.h:1070
The type of &#39;nullptr&#39;.
Definition: ASTBitCodes.h:852
Record code for the table of offsets into the block of source-location information.
Definition: ASTBitCodes.h:466
A SubstTemplateTypeParmPackType record.
Definition: ASTBitCodes.h:1043
TypeCode
Record codes for each kind of type.
Definition: ASTBitCodes.h:936
PPEntityOffset(SourceRange R, uint32_t BitOffset)
Definition: ASTBitCodes.h:188
The block containing information about the source manager.
Definition: ASTBitCodes.h:234
The placeholder type for OpenMP array section.
Definition: ASTBitCodes.h:909
A VariableArrayType record.
Definition: ASTBitCodes.h:965
unsigned getLocalFastQualifiers() const
Definition: Type.h:681
const unsigned int NUM_PREDEF_PP_ENTITY_IDS
The number of predefined preprocessed entity IDs.
Definition: ASTBitCodes.h:223
ASTRecordTypes
Record types that occur within the AST block itself.
Definition: ASTBitCodes.h:371
Defines the major attributes of a submodule, including its name and parent.
Definition: ASTBitCodes.h:703
The &#39;__uint128_t&#39; type.
Definition: ASTBitCodes.h:846
OverloadedOperatorKind getOperatorKind() const
Definition: ASTBitCodes.h:1985
A CXXDeductionGuideDecl record.
Definition: ASTBitCodes.h:1330
friend bool operator>(const ObjCCategoriesInfo &X, const ObjCCategoriesInfo &Y)
Definition: ASTBitCodes.h:1936
A StaticAssertDecl record.
Definition: ASTBitCodes.h:1390
A VarTemplateSpecializationDecl record.
Definition: ASTBitCodes.h:1369
Record code for the table of offsets of each macro ID.
Definition: ASTBitCodes.h:582
An ObjCTypeParamDecl record.
Definition: ASTBitCodes.h:1423
A record containing CXXBaseSpecifiers.
Definition: ASTBitCodes.h:1393
Specifies some declarations with initializers that must be emitted to initialize the module...
Definition: ASTBitCodes.h:755
An TemplateSpecializationType record.
Definition: ASTBitCodes.h:1022
An ObjCObjectPointerType record.
Definition: ASTBitCodes.h:998
An ObjCInterfaceType record.
Definition: ASTBitCodes.h:995
Describes a zlib-compressed blob that contains the data for a buffer entry.
Definition: ASTBitCodes.h:650
A ObjCCategoryImplDecl record.
Definition: ASTBitCodes.h:1227
SourceLocation getEnd() const
Definition: ASTBitCodes.h:196
Record code for the array of VTable uses.
Definition: ASTBitCodes.h:487
The &#39;char&#39; type, when it is unsigned.
Definition: ASTBitCodes.h:792
The directory that the PCH was originally created in.
Definition: ASTBitCodes.h:297
A ObjCPropertyImplDecl record.
Definition: ASTBitCodes.h:1239
const FunctionProtoType * T
The placeholder type for overloaded function sets.
Definition: ASTBitCodes.h:840
Record code for the table of offsets to entries in the preprocessing record.
Definition: ASTBitCodes.h:484
Field designator where only the field name is known.
Definition: ASTBitCodes.h:1872
A CXXConstructorDecl record.
Definition: ASTBitCodes.h:1336
The OpenCL &#39;half&#39; / ARM NEON __fp16 type.
Definition: ASTBitCodes.h:882
Defines an enumeration for C++ overloaded operators.
The block containing the detailed preprocessing record.
Definition: ASTBitCodes.h:245
Record code for #pragma diagnostic mappings.
Definition: ASTBitCodes.h:351
A CXXStdInitializerListExpr record.
Definition: ASTBitCodes.h:1747
A record containing CXXCtorInitializers.
Definition: ASTBitCodes.h:1396
A VarTemplateDecl record.
Definition: ASTBitCodes.h:1366
Record code for the original file that was used to generate the AST file, including both its file ID ...
Definition: ASTBitCodes.h:294
An ArraySubscriptExpr record.
Definition: ASTBitCodes.h:1553
The &#39;long double&#39; type.
Definition: ASTBitCodes.h:837
An ArrayInitLoopExpr record.
Definition: ASTBitCodes.h:1595
Record code for the diagnostic options table.
Definition: ASTBitCodes.h:348
uint32_t IdentifierID
An ID number that refers to an identifier in an AST file.
Definition: ASTBitCodes.h:61
A PseudoObjectExpr record.
Definition: ASTBitCodes.h:1631
A CXXDestructorDecl record.
Definition: ASTBitCodes.h:1342
A FunctionProtoType record.
Definition: ASTBitCodes.h:977
A NonTypeTemplateParmDecl record that stores an expanded non-type template parameter pack...
Definition: ASTBitCodes.h:1403
Defines the clang::IdentifierInfo, clang::IdentifierTable, and clang::Selector interfaces.
Describes a source location entry (SLocEntry) for a file.
Definition: ASTBitCodes.h:636
An ObjCIndirectCopyRestoreExpr record.
Definition: ASTBitCodes.h:1673
A block containing a module file extension.
Definition: ASTBitCodes.h:272
static bool isEqual(QualType A, QualType B)
Definition: ASTBitCodes.h:116
A NamespaceAliasDecl record.
Definition: ASTBitCodes.h:1297
Record code for an update to a decl context&#39;s lookup table.
Definition: ASTBitCodes.h:514
Record code for #pragma ms_struct options.
Definition: ASTBitCodes.h:608
const unsigned VERSION_MINOR
AST file minor version number supported by this version of Clang.
Definition: ASTBitCodes.h:55
friend bool operator>=(const LocalRedeclarationsInfo &X, const LocalRedeclarationsInfo &Y)
Definition: ASTBitCodes.h:1917
A DesignatedInitUpdateExpr record.
Definition: ASTBitCodes.h:1589
friend bool operator<(const LocalRedeclarationsInfo &X, const LocalRedeclarationsInfo &Y)
Definition: ASTBitCodes.h:1902
An ImplicitParamDecl record.
Definition: ASTBitCodes.h:1251
An ObjCAvailabilityCheckExpr record.
Definition: ASTBitCodes.h:1700
An EnumConstantDecl record.
Definition: ASTBitCodes.h:1203
Record code for the table of offsets of each identifier ID.
Definition: ASTBitCodes.h:404
Record code for undefined but used functions and variables that need a definition in this TU...
Definition: ASTBitCodes.h:591
A DependentNameType record.
Definition: ASTBitCodes.h:1025
do v
Definition: arm_acle.h:78
__UINTPTR_TYPE__ uintptr_t
An unsigned integer type with the property that any valid pointer to void can be converted to this ty...
Definition: opencl-c.h:82
An ImportDecl recording a module import.
Definition: ASTBitCodes.h:1414
A ObjCCategoryDecl record.
Definition: ASTBitCodes.h:1224
An ObjCForCollectionStmt record.
Definition: ASTBitCodes.h:1676
Record code for the identifier table.
Definition: ASTBitCodes.h:423
A ObjCCompatibleAliasDecl record.
Definition: ASTBitCodes.h:1233
The placeholder type for bound member functions.
Definition: ASTBitCodes.h:873
A MS-style AsmStmt record.
Definition: ASTBitCodes.h:1514
friend bool operator>=(const ObjCCategoriesInfo &X, const ObjCCategoriesInfo &Y)
Definition: ASTBitCodes.h:1946
const unsigned int NUM_PREDEF_IDENT_IDS
The number of predefined identifier IDs.
Definition: ASTBitCodes.h:138
The Objective-C &#39;Class&#39; type.
Definition: ASTBitCodes.h:1130
uint32_t SubmoduleID
An ID number that refers to a submodule in a module file.
Definition: ASTBitCodes.h:172
The &#39;unsigned long long&#39; type.
Definition: ASTBitCodes.h:807
Record code for the set of source location entries that need to be preloaded by the AST reader...
Definition: ASTBitCodes.h:474
The list of delegating constructor declarations.
Definition: ASTBitCodes.h:540
Record code for types associated with OpenCL extensions.
Definition: ASTBitCodes.h:618
An UnresolvedUsingValueDecl record.
Definition: ASTBitCodes.h:1315
Kind
Encodes a location in the source.
A record that stores the set of declarations that are visible from a given DeclContext.
Definition: ASTBitCodes.h:1288
Specifies a library or framework to link against.
Definition: ASTBitCodes.h:734
Record code for file ID of the file or buffer that was used to generate the AST file.
Definition: ASTBitCodes.h:301
Specifies a header that falls into this (sub)module.
Definition: ASTBitCodes.h:710
A ComplexType record.
Definition: ASTBitCodes.h:941
Record code for special CUDA declarations.
Definition: ASTBitCodes.h:528
A list of "interesting" identifiers.
Definition: ASTBitCodes.h:587
The block of configuration options, used to check that a module is being used in a configuration comp...
Definition: ASTBitCodes.h:269
PredefinedTypeIDs
Predefined type IDs.
Definition: ASTBitCodes.h:781
This is so that older clang versions, before the introduction of the control block, can read and reject the newer PCH format.
Definition: ASTBitCodes.h:409
The &#39;unsigned char&#39; type.
Definition: ASTBitCodes.h:795
Metadata describing this particular extension.
Definition: ASTBitCodes.h:357
An ObjCTypeParamType record.
Definition: ASTBitCodes.h:1064
The (signed) &#39;long&#39; type.
Definition: ASTBitCodes.h:825
A CXXFunctionalCastExpr record.
Definition: ASTBitCodes.h:1741
Record code for the offsets of each decl.
Definition: ASTBitCodes.h:396
Metadata for submodules as a whole.
Definition: ASTBitCodes.h:699
An ObjCEncodeExpr record.
Definition: ASTBitCodes.h:1646
A TypeOfExprType record.
Definition: ASTBitCodes.h:983
Record code for late parsed template functions.
Definition: ASTBitCodes.h:594
The (signed) &#39;short&#39; type.
Definition: ASTBitCodes.h:819
A TemplateTypeParmDecl record.
Definition: ASTBitCodes.h:1378
The internal &#39;instancetype&#39; typedef.
Definition: ASTBitCodes.h:1142
OptionsRecordTypes
Record types that occur within the options block inside the control block.
Definition: ASTBitCodes.h:320
SourceLocation getLocation() const
Definition: ASTBitCodes.h:217
IdentifierInfo * getIdentifier() const
Definition: ASTBitCodes.h:1971
Describes the categories of an Objective-C class.
Definition: ASTBitCodes.h:1924
The AST block, which acts as a container around the full AST block.
Definition: ASTBitCodes.h:230
An ObjCIsa Expr record.
Definition: ASTBitCodes.h:1670
A DeducedTemplateSpecializationType record.
Definition: ASTBitCodes.h:1067
SubmoduleRecordTypes
Record types used within a submodule description block.
Definition: ASTBitCodes.h:697
uint32_t TypeID
An ID number that refers to a type in an AST file.
Definition: ASTBitCodes.h:86
const unsigned int DECL_UPDATES
Record of updates for a declaration that was modified after being deserialized.
Definition: ASTBitCodes.h:1177
UnhashedControlBlockRecordTypes
Record codes for the unhashed control block.
Definition: ASTBitCodes.h:343
An InjectedClassNameType record.
Definition: ASTBitCodes.h:1013
Record code for the extra statistics we gather while generating an AST file.
Definition: ASTBitCodes.h:446
A NamespaceDecl record.
Definition: ASTBitCodes.h:1294
An AtomicExpr record.
Definition: ASTBitCodes.h:1634
uint32_t PreprocessedEntityID
An ID number that refers to an entity in the detailed preprocessing record.
Definition: ASTBitCodes.h:169
static QualType getFromOpaquePtr(const void *Ptr)
Definition: Type.h:701
The &#39;signed char&#39; type.
Definition: ASTBitCodes.h:813
Record code for the signature that identifiers this AST file.
Definition: ASTBitCodes.h:345
Record code for referenced selector pool.
Definition: ASTBitCodes.h:492
Record code for the set of non-builtin, special types.
Definition: ASTBitCodes.h:442
A ObjCProtocolDecl record.
Definition: ASTBitCodes.h:1215
friend bool operator<=(const LocalRedeclarationsInfo &X, const LocalRedeclarationsInfo &Y)
Definition: ASTBitCodes.h:1912
The ObjC &#39;id&#39; type.
Definition: ASTBitCodes.h:861
Record code for the list of other AST files imported by this AST file.
Definition: ASTBitCodes.h:289
A CXXConversionDecl record.
Definition: ASTBitCodes.h:1345
Describes a macro definition within the preprocessing record.
Definition: ASTBitCodes.h:689
The internal &#39;__NSConstantString&#39; typedef.
Definition: ASTBitCodes.h:1160
Record code for the module name.
Definition: ASTBitCodes.h:308
uint32_t SelectorID
An ID number that refers to an ObjC selector in an AST file.
Definition: ASTBitCodes.h:154
Dataflow Directional Tag Classes.
An InitListExpr record.
Definition: ASTBitCodes.h:1583
Describes an inclusion directive within the preprocessing record.
Definition: ASTBitCodes.h:693
The internal &#39;__builtin_ms_va_list&#39; typedef.
Definition: ASTBitCodes.h:1151
Record code for a file sorted array of DeclIDs in a module.
Definition: ASTBitCodes.h:561
A CXXBoolLiteralExpr record.
Definition: ASTBitCodes.h:1750
Record code for the array of Objective-C categories (including extensions).
Definition: ASTBitCodes.h:575
Specifies a configuration macro for this module.
Definition: ASTBitCodes.h:737
PreprocessorDetailRecordTypes
Record types used within a preprocessor detail block.
Definition: ASTBitCodes.h:684
OverloadedOperatorKind
Enumeration specifying the different kinds of C++ overloaded operators.
Definition: OperatorKinds.h:22
TypeID asTypeID(unsigned FastQuals) const
Definition: ASTBitCodes.h:98
An ExtVectorElementExpr record.
Definition: ASTBitCodes.h:1580
Record code for the array of unused file scoped decls.
Definition: ASTBitCodes.h:480
A FunctionNoProtoType record.
Definition: ASTBitCodes.h:974
A ClassTemplatePartialSpecializationDecl record.
Definition: ASTBitCodes.h:1363
static clang::serialization::DeclarationNameKey getEmptyKey()
Definition: ASTBitCodes.h:2007
DeclCode
Record codes for each kind of declaration.
Definition: ASTBitCodes.h:1189
An ObjCAutoreleasePoolStmt record.
Definition: ASTBitCodes.h:1694
DeclarationName - The name of a declaration.
A ClassScopeFunctionSpecializationDecl record a class scope function specialization.
Definition: ASTBitCodes.h:1411
Record code for the Objective-C method pool,.
Definition: ASTBitCodes.h:458
Specifies a header that is private to this submodule.
Definition: ASTBitCodes.h:743
A LinkageSpecDecl record.
Definition: ASTBitCodes.h:1321
Describes a macro expansion within the preprocessing record.
Definition: ASTBitCodes.h:686
A CXXDynamicCastExpr record.
Definition: ASTBitCodes.h:1732
An EnumType record.
Definition: ASTBitCodes.h:992
An RValueReferenceType record.
Definition: ASTBitCodes.h:953
DeclarationNameKey(NameKind Kind, uint64_t Data)
Definition: ASTBitCodes.h:1966
uint32_t DeclID
An ID number that refers to a declaration in an AST file.
Definition: ASTBitCodes.h:69
An AtomicType record.
Definition: ASTBitCodes.h:1052
An ObjCAtFinallyStmt record.
Definition: ASTBitCodes.h:1682
The placeholder type for dependent types.
Definition: ASTBitCodes.h:843
Number of unmatched #pragma clang cuda_force_host_device begin directives we&#39;ve seen.
Definition: ASTBitCodes.h:615
A PragmaCommentDecl record.
Definition: ASTBitCodes.h:1429
Record code for the table of offsets into the Objective-C method pool.
Definition: ASTBitCodes.h:455
A DependentSizedArrayType record.
Definition: ASTBitCodes.h:1031
Record code for the remapping information used to relate loaded modules to the various offsets and ID...
Definition: ASTBitCodes.h:550
An ObjCAtSynchronizedStmt record.
Definition: ASTBitCodes.h:1688
uint32_t IdentID
An ID number that refers to an identifier in an AST file.
Definition: ASTBitCodes.h:135
A key used when looking up entities by DeclarationName.
Definition: ASTBitCodes.h:1957
Record code for declarations that Sema keeps references of.
Definition: ASTBitCodes.h:501
const unsigned int NUM_PREDEF_MACRO_IDS
The number of predefined macro IDs.
Definition: ASTBitCodes.h:151
Offsets into the input-files block where input files reside.
Definition: ASTBitCodes.h:305
A CXXMemberCallExpr record.
Definition: ASTBitCodes.h:1717
PreprocessorRecordTypes
Record types used within a preprocessor block.
Definition: ASTBitCodes.h:658
The block containing the submodule structure.
Definition: ASTBitCodes.h:248
void setLocation(SourceLocation L)
Definition: ASTBitCodes.h:213
uint32_t CXXBaseSpecifiersID
An ID number that refers to a set of CXXBaseSpecifiers in an AST file.
Definition: ASTBitCodes.h:161
A ConvertVectorExpr record.
Definition: ASTBitCodes.h:1622
unsigned End
Raw source location of end of range.
Definition: ASTBitCodes.h:183
A TypedefType record.
Definition: ASTBitCodes.h:980
X
Add a minimal nested name specifier fixit hint to allow lookup of a tag name from an outer enclosing ...
Definition: SemaDecl.cpp:13010
DeclOffset(SourceLocation Loc, uint32_t BitOffset)
Definition: ASTBitCodes.h:210
GNU array range designator.
Definition: ASTBitCodes.h:1882
The C++ &#39;char16_t&#39; type.
Definition: ASTBitCodes.h:855
Defines the clang::SourceLocation class and associated facilities.
An ArrayInitIndexExpr record.
Definition: ASTBitCodes.h:1598
A GCC-style AsmStmt record.
Definition: ASTBitCodes.h:1511
An TemplateTypeParmType record.
Definition: ASTBitCodes.h:1019
Record code for the filesystem options table.
Definition: ASTBitCodes.h:333
An ObjCAtCatchStmt record.
Definition: ASTBitCodes.h:1679
A ObjCImplementationDecl record.
Definition: ASTBitCodes.h:1230
uint32_t CXXCtorInitializersID
An ID number that refers to a list of CXXCtorInitializers in an AST file.
Definition: ASTBitCodes.h:165
Field designator where the field has been resolved to a declaration.
Definition: ASTBitCodes.h:1876
static unsigned getHashValue(const clang::serialization::DeclarationNameKey &Key)
Definition: ASTBitCodes.h:2016
A ObjCAtDefsFieldDecl record.
Definition: ASTBitCodes.h:1221
Record code for the offsets of each type.
Definition: ASTBitCodes.h:384
A DependentAddressSpaceType record.
Definition: ASTBitCodes.h:1073
A CXXInheritedCtorInitExpr record.
Definition: ASTBitCodes.h:1723
The block containing the definitions of all of the types and decls used within the AST file...
Definition: ASTBitCodes.h:242
The internal &#39;__va_list_tag&#39; struct, if any.
Definition: ASTBitCodes.h:1148
const unsigned int LOCAL_REDECLARATIONS
Record code for a list of local redeclarations of a declaration.
Definition: ASTBitCodes.h:1181
A TypeAliasDecl record.
Definition: ASTBitCodes.h:1194
Specifies the name of the module that will eventually re-export the entities in this module...
Definition: ASTBitCodes.h:759
Describes the redeclarations of a declaration.
Definition: ASTBitCodes.h:1895
The (signed) &#39;int&#39; type.
Definition: ASTBitCodes.h:822
Specifies a required feature.
Definition: ASTBitCodes.h:727
An ExportDecl record.
Definition: ASTBitCodes.h:1324
Record for offsets of DECL_UPDATES records for declarations that were modified after being deserializ...
Definition: ASTBitCodes.h:518
The C++ &#39;wchar_t&#39; type.
Definition: ASTBitCodes.h:816
The ObjC &#39;Class&#39; type.
Definition: ASTBitCodes.h:864
A FunctionTemplateDecl record.
Definition: ASTBitCodes.h:1375
A TypeAliasTemplateDecl record.
Definition: ASTBitCodes.h:1387
Record code for weak undeclared identifiers.
Definition: ASTBitCodes.h:504
The block containing information about the preprocessor.
Definition: ASTBitCodes.h:238
Record code for the headers search options table.
Definition: ASTBitCodes.h:336
A trivial tuple used to represent a source range.
AST file metadata, including the AST file version number and information about the compiler used to b...
Definition: ASTBitCodes.h:285
The block of input files, which were used as inputs to create this AST file.
Definition: ASTBitCodes.h:262
The internal &#39;__NSConstantString&#39; tag type.
Definition: ASTBitCodes.h:1163
static TypeIdx fromTypeID(TypeID ID)
Definition: ASTBitCodes.h:105
InputFileRecordTypes
Record types that occur within the input-files block inside the control block.
Definition: ASTBitCodes.h:365
A function-like macro definition.
Definition: ASTBitCodes.h:669
The Objective-C &#39;Protocol&#39; type.
Definition: ASTBitCodes.h:1133
The control block, which contains all of the information that needs to be validated prior to committi...
Definition: ASTBitCodes.h:256
StmtCode
Record codes for each kind of statement or expression.
Definition: ASTBitCodes.h:1445
PredefinedDeclIDs
Predefined declaration IDs.
Definition: ASTBitCodes.h:1116
Record code for an update to the TU&#39;s lexically contained declarations.
Definition: ASTBitCodes.h:496
Source range/offset of a preprocessed entity.
Definition: ASTBitCodes.h:202
A GenericSelectionExpr record.
Definition: ASTBitCodes.h:1628
A type index; the type ID with the qualifier bits removed.
Definition: ASTBitCodes.h:89
Objective-C "Class" redefinition type.
Definition: ASTBitCodes.h:1098
A PackExpansionType record.
Definition: ASTBitCodes.h:1037
The pseudo-object placeholder type.
Definition: ASTBitCodes.h:888
const unsigned int NUM_PREDEF_SUBMODULE_IDS
The number of predefined submodule IDs.
Definition: ASTBitCodes.h:175
Record code for #pragma ms_struct options.
Definition: ASTBitCodes.h:611
A DependentTemplateSpecializationType record.
Definition: ASTBitCodes.h:1028
Record code for the array of tentative definitions.
Definition: ASTBitCodes.h:449
The &#39;__float128&#39; type.
Definition: ASTBitCodes.h:912