Tweak Sema::ActOnInstanceMessage() to treat the built-in "Class" type the same as "id".

llvm-svn: 43996
This commit is contained in:
Steve Naroff 2007-11-11 17:52:25 +00:00
parent cac26f4f5f
commit 49effdefef
1 changed files with 2 additions and 1 deletions

View File

@ -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(),