diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2010-09-05 23:15:52 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2010-09-05 23:15:52 +0000 |
commit | 957c094bd435c9ae367a9fcf375a5fadcc0c2bff (patch) | |
tree | f6b20a140618c36ee8eef9e84aca75d2415d5688 /lib | |
parent | 271b665c4e357809d245c1ab811f20bf1f0dfc1f (diff) |
PR8023: Don't crash on invalid uses of __real__ on class types in C++.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113124 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Sema/SemaExpr.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 815a962262..80b465230e 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -6796,7 +6796,7 @@ ExprResult Sema::BuildUnaryOp(Scope *S, SourceLocation OpLoc, UnaryOperatorKind Opc, Expr *Input) { if (getLangOptions().CPlusPlus && Input->getType()->isOverloadableType() && - Opc != UO_Extension) { + UnaryOperator::getOverloadedOperator(Opc) != OO_None) { // Find all of the overloaded operators visible from this // point. We perform both an operator-name lookup from the local // scope and an argument-dependent lookup based on the types of |