aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaOverload.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-10-26 06:40:27 +0000
committerJohn McCall <rjmccall@apple.com>2010-10-26 06:40:27 +0000
commit202422eea3b7c1c455edd168e6e79a50e732d7a9 (patch)
tree8074b959a0ac7c74be765a266d632522d883f270 /lib/Sema/SemaOverload.cpp
parent6d09da00bf5b5841380eae76571798ced6697f4c (diff)
Actually, that doesn't really work, and anyway we should choose
conversion to id over conversion to void*. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117355 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaOverload.cpp')
-rw-r--r--lib/Sema/SemaOverload.cpp11
1 files changed, 1 insertions, 10 deletions
diff --git a/lib/Sema/SemaOverload.cpp b/lib/Sema/SemaOverload.cpp
index 7244582829..8f653d1df0 100644
--- a/lib/Sema/SemaOverload.cpp
+++ b/lib/Sema/SemaOverload.cpp
@@ -200,9 +200,6 @@ bool StandardConversionSequence::isPointerConversionToBool() const {
/// conversion is a conversion of a pointer to a void pointer. This is
/// used as part of the ranking of standard conversion sequences (C++
/// 13.3.3.2p4).
-///
-/// Note that we treat conversions of Objective-C pointers to
-/// unqualified 'id' as having this same rank.
bool
StandardConversionSequence::
isPointerConversionToVoidPointer(ASTContext& Context) const {
@@ -215,15 +212,9 @@ isPointerConversionToVoidPointer(ASTContext& Context) const {
if (First == ICK_Array_To_Pointer)
FromType = Context.getArrayDecayedType(FromType);
- if (Second == ICK_Pointer_Conversion && FromType->isPointerType()) {
+ if (Second == ICK_Pointer_Conversion && FromType->isPointerType())
if (const PointerType* ToPtrType = ToType->getAs<PointerType>())
return ToPtrType->getPointeeType()->isVoidType();
- } else if (Second == ICK_Pointer_Conversion &&
- FromType->isObjCObjectPointerType()) {
- if (const ObjCObjectPointerType *ToPtrType =
- ToType->getAs<ObjCObjectPointerType>())
- return ToPtrType->isObjCIdType();
- }
return false;
}