зеркало из https://github.com/microsoft/clang-1.git
Support unary type traits in a scalar context. Not that I've actually seen
this construct, but might as well for completeness. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91071 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
29a7f3342c
Коммит
9dfebdcdcd
|
@ -263,6 +263,10 @@ public:
|
|||
CGF.EmitCXXDeleteExpr(E);
|
||||
return 0;
|
||||
}
|
||||
Value *VisitUnaryTypeTraitExpr(const UnaryTypeTraitExpr *E) {
|
||||
return llvm::ConstantInt::get(Builder.getInt1Ty(),
|
||||
E->EvaluateTrait(CGF.getContext()));
|
||||
}
|
||||
|
||||
Value *VisitCXXPseudoDestructorExpr(const CXXPseudoDestructorExpr *E) {
|
||||
// C++ [expr.pseudo]p1:
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
// RUN: clang-cc -emit-llvm-only -verify %s
|
||||
|
||||
bool a() { return __is_pod(int); }
|
Загрузка…
Ссылка в новой задаче