if (DeclKind >= FunctionFirst && DeclKind <= FunctionLast)
return IDNS_Ordinary;
assert(0 && "Unknown decl kind!");
- case ImplicitParam:
+ case OverloadedFunction:
case Typedef:
+ case TemplateTypeParm:
+ case EnumConstant:
case Var:
+ case CXXClassVar:
+ case ImplicitParam:
case ParmVar:
case OriginalParmVar:
- case EnumConstant:
case NonTypeTemplateParm:
+ case ObjCMethod:
+ case ObjCContainer:
+ case ObjCCategory:
+ case ObjCProtocol:
case ObjCInterface:
+ case ObjCCategoryImpl:
+ case ObjCProperty:
case ObjCCompatibleAlias:
- case OverloadedFunction:
- case CXXMethod:
- case CXXConversion:
- case CXXClassVar:
return IDNS_Ordinary;
case Field:
case Record:
case CXXRecord:
- case TemplateTypeParm:
case Enum:
return IDNS_Tag;
+
case Namespace:
return IdentifierNamespace(IDNS_Tag | IDNS_Ordinary);
}
// assignment, to the types of the corresponding parameter, ...
unsigned NumArgsInProto = Proto->getNumArgs();
unsigned NumArgsToCheck = NumArgs;
-
+ bool Invalid = false;
+
// If too few arguments are available (and we don't have default
// arguments for the remaining parameters), don't make the call.
if (NumArgs < NumArgsInProto) {
Args[NumArgs-1]->getLocEnd());
// This deletes the extra arguments.
Call->setNumArgs(NumArgsInProto);
+ Invalid = true;
}
NumArgsToCheck = NumArgsInProto;
}
}
}
- return false;
+ return Invalid;
}
/// ActOnCallExpr - Handle a call to Fn with the specified array of arguments.