invocation-expression-missing-arguments
Available in: KerML, SysML
This checks that invocation expressions provide arguments to all parameters without feature values.
Parameters without feature values are an issue because they typically cannot be used to
evaluate expressions. This is less of an issue in constructor expressions because
arguments implicitly bind to public features that may or may not be used in expressions.
Example
calc def C {
in attribute x;
in attribute y default 3;
x * y
}
attribute a = C(); // warning: Argument missing for parameter `x`
attribute b = C(y=2); // warning: Argument missing for parameter `x`
attribute c = C(x=2); // ok
Fix this by providing values to parameters without feature values:
calc def C {
in attribute x;
in attribute y default 3;
x * y
}
attribute a = C(x=1); // ok
attribute b = C(x=3, y=2); // ok
Options
lint.invocation-expression-missing-argumentsAllows controlling the diagnostic severity, e.g.
offto disable it.