Author: fjahanian
Date: Sat Dec  6 17:12:49 2008
New Revision: 60635

URL: http://llvm.org/viewvc/llvm-project?rev=60635&view=rev
Log:
Setters returning a typedef of 'void' should not cause error.
Bug reported by Chris L.

Modified:
    cfe/trunk/lib/Sema/SemaDeclObjC.cpp

Modified: cfe/trunk/lib/Sema/SemaDeclObjC.cpp
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclObjC.cpp?rev=60635&r1=60634&r2=60635&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclObjC.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclObjC.cpp Sat Dec  6 17:12:49 2008
@@ -992,7 +992,8 @@
   }
   
   if (SetterMethod) {
-    if (SetterMethod->getResultType() != Context.VoidTy)
+    if (Context.getCanonicalType(SetterMethod->getResultType()) 
+        != Context.VoidTy)
       Diag(SetterMethod->getLocation(), diag::err_setter_type_void);
     if (SetterMethod->getNumParams() != 1 ||
         (SetterMethod->getParamDecl(0)->getType() != property->getType())) {


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to