Swaps wrong_args globally

This commit is contained in:
Rebecca Valentine
2020-02-25 11:00:39 -08:00
parent 3a764ade8d
commit fb0cae76cf
2 changed files with 2 additions and 2 deletions

View File

@@ -107,7 +107,7 @@ predicate too_many_args_objectapi(Call call, Object callable, int limit) {
}
/** Holds if `call` has too many or too few arguments for `func` */
predicate wrong_args(Call call, FunctionObject func, int limit, string too) {
predicate wrong_args_objectapi(Call call, FunctionObject func, int limit, string too) {
too_few_args_objectapi(call, func, limit) and too = "too few"
or
too_many_args_objectapi(call, func, limit) and too = "too many"

View File

@@ -15,7 +15,7 @@ import Expressions.CallArgs
from Call call, FunctionObject func, FunctionObject overridden, string problem
where
func.overrides(overridden) and (
wrong_args(call, func, _, problem) and correct_args_if_called_as_method(call, overridden)
wrong_args_objectapi(call, func, _, problem) and correct_args_if_called_as_method(call, overridden)
or
exists(string name |
illegally_named_parameter_objectapi(call, func, name) and problem = "an argument named '" + name + "'" and