aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-04-01 22:47:07 +0000
committerDouglas Gregor <dgregor@apple.com>2010-04-01 22:47:07 +0000
commit1927b1f1d3194c1b9e7c3fa622542dd244f1a963 (patch)
tree53b8067a2866fc7a6dde955eceae67966631bbc7
parent699fca2d7aeb854e4c4d68b3483734b52b7cc932 (diff)
Minor cleanup with the ternary operator
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100144 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Sema/SemaExprCXX.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 8024af28d4..501c877c3d 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -2152,7 +2152,7 @@ QualType Sema::CXXCheckConditionalOperands(Expr *&Cond, Expr *&LHS, Expr *&RHS,
// C++0x 5.16p4
// If the second and third operands are lvalues and have the same type,
// the result is of that type [...]
- bool Same = Context.getCanonicalType(LTy) == Context.getCanonicalType(RTy);
+ bool Same = Context.hasSameType(LTy, RTy);
if (Same && LHS->isLvalue(Context) == Expr::LV_Valid &&
RHS->isLvalue(Context) == Expr::LV_Valid)
return LTy;
@@ -2213,7 +2213,7 @@ QualType Sema::CXXCheckConditionalOperands(Expr *&Cond, Expr *&LHS, Expr *&RHS,
return Composite;
}
- // Similarly, attempt to find composite type of twp objective-c pointers.
+ // Similarly, attempt to find composite type of two objective-c pointers.
Composite = FindCompositeObjCPointerType(LHS, RHS, QuestionLoc);
if (!Composite.isNull())
return Composite;