objc - compare setter/property types using
hasSameUnqualifiedType in //rdar://10156674
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140576 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaObjCProperty.cpp b/lib/Sema/SemaObjCProperty.cpp
index 9297bc2..db23c84 100644
--- a/lib/Sema/SemaObjCProperty.cpp
+++ b/lib/Sema/SemaObjCProperty.cpp
@@ -1481,8 +1481,8 @@
Context.VoidTy)
Diag(SetterMethod->getLocation(), diag::err_setter_type_void);
if (SetterMethod->param_size() != 1 ||
- ((*SetterMethod->param_begin())->getType().getUnqualifiedType()
- != property->getType().getUnqualifiedType())) {
+ !Context.hasSameUnqualifiedType(
+ (*SetterMethod->param_begin())->getType(), property->getType())) {
Diag(property->getLocation(),
diag::warn_accessor_property_type_mismatch)
<< property->getDeclName()