summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2012-02-23 07:33:15 +0000
committerDouglas Gregor <dgregor@apple.com>2012-02-23 07:33:15 +0000
commit25d0a0f67d9e949ffbfc57bf487012f5cbfd886e (patch)
tree2c7d3cf3e2b66d16d367e5ac545593d970f89621 /include
parent46e021e897b8319b192115954f0b2c82fe0e504d (diff)
downloadclang-25d0a0f67d9e949ffbfc57bf487012f5cbfd886e.tar.gz
clang-25d0a0f67d9e949ffbfc57bf487012f5cbfd886e.tar.bz2
clang-25d0a0f67d9e949ffbfc57bf487012f5cbfd886e.tar.xz
Provide the __is_trivially_assignable type trait, which provides
compiler support for the std::is_trivially_assignable library type trait. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151240 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/clang/AST/Expr.h4
-rw-r--r--include/clang/Basic/TokenKinds.def1
-rw-r--r--include/clang/Basic/TypeTraits.h3
3 files changed, 7 insertions, 1 deletions
diff --git a/include/clang/AST/Expr.h b/include/clang/AST/Expr.h
index d66ad8fbca..d943aba0d3 100644
--- a/include/clang/AST/Expr.h
+++ b/include/clang/AST/Expr.h
@@ -512,6 +512,10 @@ public:
/// variable read.
bool HasSideEffects(const ASTContext &Ctx) const;
+ /// \brief Determine whether this expression involves a call to any function
+ /// that is not trivial.
+ bool hasNonTrivialCall(ASTContext &Ctx);
+
/// EvaluateKnownConstInt - Call EvaluateAsRValue and return the folded
/// integer. This must be called on an expression that constant folds to an
/// integer.
diff --git a/include/clang/Basic/TokenKinds.def b/include/clang/Basic/TokenKinds.def
index 5c9708bc71..014e111033 100644
--- a/include/clang/Basic/TokenKinds.def
+++ b/include/clang/Basic/TokenKinds.def
@@ -366,6 +366,7 @@ KEYWORD(__is_union , KEYCXX)
// Clang-only C++ Type Traits
KEYWORD(__is_trivially_copyable , KEYCXX)
+KEYWORD(__is_trivially_assignable , KEYCXX)
KEYWORD(__underlying_type , KEYCXX)
// Embarcadero Expression Traits
diff --git a/include/clang/Basic/TypeTraits.h b/include/clang/Basic/TypeTraits.h
index 3ae56afae5..6ed2adfaf5 100644
--- a/include/clang/Basic/TypeTraits.h
+++ b/include/clang/Basic/TypeTraits.h
@@ -68,7 +68,8 @@ namespace clang {
BTT_IsConvertible,
BTT_IsConvertibleTo,
BTT_IsSame,
- BTT_TypeCompatible
+ BTT_TypeCompatible,
+ BTT_IsTriviallyAssignable
};
/// ArrayTypeTrait - Names for the array type traits.