From 49effdefef02e401bc9101ba7e3dd22472e7cdfe Mon Sep 17 00:00:00 2001 From: Steve Naroff Date: Sun, 11 Nov 2007 17:52:25 +0000 Subject: [PATCH] Tweak Sema::ActOnInstanceMessage() to treat the built-in "Class" type the same as "id". llvm-svn: 43996 --- clang/Sema/SemaExpr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/clang/Sema/SemaExpr.cpp b/clang/Sema/SemaExpr.cpp index 31c09be7cb8b..fe96bea69363 100644 --- a/clang/Sema/SemaExpr.cpp +++ b/clang/Sema/SemaExpr.cpp @@ -2097,7 +2097,8 @@ Sema::ExprResult Sema::ActOnInstanceMessage( QualType returnType; ObjcMethodDecl *Method; - if (receiverType == Context.getObjcIdType()) { + if (receiverType == Context.getObjcIdType() || + receiverType == Context.getObjcClassType()) { Method = InstanceMethodPool[Sel].Method; if (!Method) { Diag(lbrac, diag::warn_method_not_found, std::string("-"), Sel.getName(),