mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Remove the inaccurate Type::categoryName() and change the error message for invalid calls to one independent of the category
This commit is contained in:
@@ -2847,11 +2847,7 @@ bool TypeChecker::visit(FunctionCall const& _functionCall)
|
||||
}
|
||||
|
||||
default:
|
||||
m_errorReporter.fatalTypeError(
|
||||
5704_error,
|
||||
_functionCall.location(),
|
||||
capitalized(Type::categoryName(expressionType->category())) + " is not callable."
|
||||
);
|
||||
m_errorReporter.fatalTypeError(5704_error, _functionCall.location(), "This expression is not callable.");
|
||||
// Unreachable, because fatalTypeError throws. We don't set kind, but that's okay because the switch below
|
||||
// is never reached. And, even if it was, SetOnce would trigger an assertion violation and not UB.
|
||||
funcCallAnno.isPure = argumentsArePure;
|
||||
|
||||
Reference in New Issue
Block a user