aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2013-04-30 00:30:48 +0000
committerFariborz Jahanian <fjahanian@apple.com>2013-04-30 00:30:48 +0000
commit443adec6b06878be2180bf389ec88a68e9b5997c (patch)
treef21f69d5fbb8759bef45684a007cf04cfdfd6625 /lib
parentaa3cef411387d1c098607a98426e11386d4175d6 (diff)
Objective-C (mostly arc): Under ARC, we often have unneeded qualifiers
in the diagnostics. Remove them when reporting incompatible Objective-C pointer types. // rdar://13752880. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180765 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/Sema/SemaExpr.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index f5900c06c7..173ee1e7f8 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -10170,6 +10170,10 @@ bool Sema::DiagnoseAssignmentResult(AssignConvertType ConvTy,
if (Hint.isNull() && !CheckInferredResultType) {
ConvHints.tryToFixConversion(SrcExpr, SrcType, DstType, *this);
}
+ else if (CheckInferredResultType) {
+ SrcType = SrcType.getUnqualifiedType();
+ DstType = DstType.getUnqualifiedType();
+ }
MayHaveConvFixit = true;
break;
case IncompatiblePointerSign: