CPlusPlusForwardDeclarations.h 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. // Copyright (c) 2008 Roberto Raggi <[email protected]>
  2. //
  3. // Permission is hereby granted, free of charge, to any person obtaining a copy
  4. // of this software and associated documentation files (the "Software"), to deal
  5. // in the Software without restriction, including without limitation the rights
  6. // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  7. // copies of the Software, and to permit persons to whom the Software is
  8. // furnished to do so, subject to the following conditions:
  9. //
  10. // The above copyright notice and this permission notice shall be included in
  11. // all copies or substantial portions of the Software.
  12. //
  13. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  14. // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  15. // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  16. // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  17. // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  18. // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  19. // THE SOFTWARE.
  20. #ifndef CPLUSPLUS_CPLUSPLUSFORWARDDECLARATIONS_H
  21. #define CPLUSPLUS_CPLUSPLUSFORWARDDECLARATIONS_H
  22. #include <cstdlib>
  23. #include <cstddef>
  24. #ifdef CPLUSPLUS_WITHOUT_QT
  25. # ifndef CPLUSPLUS_UNLIKELY
  26. # ifdef __GNUC__
  27. # define CPLUSPLUS_UNLIKELY(expr) __builtin_expect(!!(expr), false)
  28. # else
  29. # define CPLUSPLUS_UNLIKELY(expr) (expr)
  30. # endif
  31. # endif
  32. # define CPLUSPLUS_EXPORT
  33. #else
  34. # include <qglobal.h>
  35. # ifndef CPLUSPLUS_UNLIKELY
  36. # ifdef Q_UNLIKELY
  37. # define CPLUSPLUS_UNLIKELY(expr) Q_UNLIKELY(expr)
  38. # else // pre 4.8.something
  39. # ifdef __GCC__
  40. # define CPLUSPLUS_UNLIKELY(expr) __builtin_expect(!!(expr), false)
  41. # else
  42. # define CPLUSPLUS_UNLIKELY(expr) (expr)
  43. # endif
  44. # endif
  45. # endif
  46. # if defined(CPLUSPLUS_BUILD_LIB)
  47. # define CPLUSPLUS_EXPORT Q_DECL_EXPORT
  48. # elif defined(CPLUSPLUS_BUILD_STATIC_LIB)
  49. # define CPLUSPLUS_EXPORT
  50. # else
  51. # define CPLUSPLUS_EXPORT Q_DECL_IMPORT
  52. # endif
  53. #endif
  54. namespace CPlusPlus {
  55. class TranslationUnit;
  56. class Control;
  57. class MemoryPool;
  58. class DiagnosticClient;
  59. class Identifier;
  60. class Literal;
  61. class StringLiteral;
  62. class NumericLiteral;
  63. class SymbolTable;
  64. // names
  65. class NameVisitor;
  66. class Name;
  67. class Identifier;
  68. class AnonymousNameId;
  69. class TemplateNameId;
  70. class DestructorNameId;
  71. class OperatorNameId;
  72. class ConversionNameId;
  73. class QualifiedNameId;
  74. class SelectorNameId;
  75. // types
  76. class Matcher;
  77. class FullySpecifiedType;
  78. class TypeVisitor;
  79. class Type;
  80. class UndefinedType;
  81. class VoidType;
  82. class IntegerType;
  83. class FloatType;
  84. class PointerToMemberType;
  85. class PointerType;
  86. class ReferenceType;
  87. class ArrayType;
  88. class NamedType;
  89. // symbols
  90. class Clone;
  91. class Subst;
  92. class SymbolVisitor;
  93. class Symbol;
  94. class Scope;
  95. class UsingNamespaceDirective;
  96. class UsingDeclaration;
  97. class Declaration;
  98. class Argument;
  99. class TypenameArgument;
  100. class Function;
  101. class Namespace;
  102. class NamespaceAlias;
  103. class Template;
  104. class BaseClass;
  105. class Block;
  106. class Class;
  107. class Enum;
  108. class EnumeratorDeclaration;
  109. class ForwardClassDeclaration;
  110. class Token;
  111. // Qt symbols
  112. class QtPropertyDeclaration;
  113. class QtEnum;
  114. // Objective-C symbols
  115. class ObjCBaseClass;
  116. class ObjCBaseProtocol;
  117. class ObjCClass;
  118. class ObjCForwardClassDeclaration;
  119. class ObjCProtocol;
  120. class ObjCForwardProtocolDeclaration;
  121. class ObjCMethod;
  122. class ObjCPropertyDeclaration;
  123. } // namespace CPlusPlus
  124. #endif // CPLUSPLUS_CPLUSPLUSFORWARDDECLARATIONS_H