• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===--- TypeTraits.h - C++ Type Traits Support Enumerations ----*- 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 file defines enumerations for the type traits support.
11 //
12 //===----------------------------------------------------------------------===//
13 
14 #ifndef LLVM_CLANG_TYPETRAITS_H
15 #define LLVM_CLANG_TYPETRAITS_H
16 
17 namespace clang {
18 
19   /// UnaryTypeTrait - Names for the unary type traits.
20   enum UnaryTypeTrait {
21     UTT_HasNothrowAssign,
22     UTT_HasNothrowCopy,
23     UTT_HasNothrowConstructor,
24     UTT_HasTrivialAssign,
25     UTT_HasTrivialCopy,
26     UTT_HasTrivialDefaultConstructor,
27     UTT_HasTrivialDestructor,
28     UTT_HasVirtualDestructor,
29     UTT_IsAbstract,
30     UTT_IsArithmetic,
31     UTT_IsArray,
32     UTT_IsClass,
33     UTT_IsCompleteType,
34     UTT_IsCompound,
35     UTT_IsConst,
36     UTT_IsEmpty,
37     UTT_IsEnum,
38     UTT_IsFinal,
39     UTT_IsFloatingPoint,
40     UTT_IsFunction,
41     UTT_IsFundamental,
42     UTT_IsIntegral,
43     UTT_IsLiteral,
44     UTT_IsLvalueReference,
45     UTT_IsMemberFunctionPointer,
46     UTT_IsMemberObjectPointer,
47     UTT_IsMemberPointer,
48     UTT_IsObject,
49     UTT_IsPOD,
50     UTT_IsPointer,
51     UTT_IsPolymorphic,
52     UTT_IsReference,
53     UTT_IsRvalueReference,
54     UTT_IsScalar,
55     UTT_IsSigned,
56     UTT_IsStandardLayout,
57     UTT_IsTrivial,
58     UTT_IsTriviallyCopyable,
59     UTT_IsUnion,
60     UTT_IsUnsigned,
61     UTT_IsVoid,
62     UTT_IsVolatile
63   };
64 
65   /// BinaryTypeTrait - Names for the binary type traits.
66   enum BinaryTypeTrait {
67     BTT_IsBaseOf,
68     BTT_IsConvertible,
69     BTT_IsConvertibleTo,
70     BTT_IsSame,
71     BTT_TypeCompatible,
72     BTT_IsTriviallyAssignable
73   };
74 
75   /// ArrayTypeTrait - Names for the array type traits.
76   enum ArrayTypeTrait {
77     ATT_ArrayRank,
78     ATT_ArrayExtent
79   };
80 
81   /// UnaryExprOrTypeTrait - Names for the "expression or type" traits.
82   enum UnaryExprOrTypeTrait {
83     UETT_SizeOf,
84     UETT_AlignOf,
85     UETT_VecStep
86   };
87 
88   /// \brief Names for type traits that operate specifically on types.
89   enum TypeTrait {
90     TT_IsTriviallyConstructible
91   };
92 
93 }
94 
95 #endif
96