Don't complain about block pointer to void* conversions

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60138 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/Sema.h b/lib/Sema/Sema.h
index 614e487..57caa6e 100644
--- a/lib/Sema/Sema.h
+++ b/lib/Sema/Sema.h
@@ -1166,10 +1166,6 @@
     /// pointers types that are not compatible.
     IncompatibleBlockPointer,
     
-    /// BlockVoidPointer - The assignment is between a block pointer and
-    /// void*, we accept for now.
-    BlockVoidPointer,
-    
     /// IncompatibleObjCQualifiedId - The assignment is between a qualified
     /// id type and something else (that is incompatible with it). For example,
     /// "id <XXX>" = "Foo *", where "Foo *" doesn't implement the XXX protocol.
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index b22ae7d..e21047e 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -1917,7 +1917,7 @@
       
     if (rhsType->getAsBlockPointerType()) {
       if (lhsType->getAsPointerType()->getPointeeType()->isVoidType())
-        return BlockVoidPointer;
+        return Compatible;
 
       // Treat block pointers as objects.
       if (getLangOptions().ObjC1 &&
@@ -1941,7 +1941,7 @@
       
     if (const PointerType *RHSPT = rhsType->getAsPointerType()) {
       if (RHSPT->getPointeeType()->isVoidType())
-        return BlockVoidPointer;
+        return Compatible;
     }
     return Incompatible;
   }
@@ -1959,7 +1959,7 @@
       
     if (isa<BlockPointerType>(lhsType) && 
         rhsType->getAsPointerType()->getPointeeType()->isVoidType())
-      return BlockVoidPointer;
+      return Compatible;
     return Incompatible;
   }
 
@@ -3646,9 +3646,6 @@
   case IncompatibleBlockPointer:
     DiagKind = diag::ext_typecheck_convert_incompatible_block_pointer;
     break;
-  case BlockVoidPointer:
-    DiagKind = diag::ext_typecheck_convert_pointer_void_block;
-    break;
   case IncompatibleObjCQualifiedId:
     // FIXME: Diagnose the problem in ObjCQualifiedIdTypesAreCompatible, since 
     // it can give a more specific diagnostic.