You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 23, 2024. It is now read-only.
Currently, the reference from a call to a function def is resolved by simply comparing the name of the call to the name of the def.
If there are many function defs with the same name, they are all referenced.
Desired solution
The results are most likely to improve if only functions with the same number of parameters (=arity) are referenced.
Therefore, a check must be implemented that compares the number of parameters of a call to the number of arguments of a function def.
Possible alternatives (optional)
No response
Screenshots (optional)
No response
Additional Context (optional)
Functions with star arguments (*args | **kwargs) require special treatment.
The text was updated successfully, but these errors were encountered:
Closes#252
### Summary of Changes
Implemented a function that compares the arguments of a call with the
parameters of the function when resolving function references. It checks
the arity of the call and the names of the keyword arguments (if any) to
reduce the possible references for function calls where more than one
function def matches by name.
---------
Co-authored-by: megalinter-bot <[email protected]>
Is your feature request related to a problem?
Currently, the reference from a call to a function def is resolved by simply comparing the name of the call to the name of the def.
If there are many function defs with the same name, they are all referenced.
Desired solution
The results are most likely to improve if only functions with the same number of parameters (=arity) are referenced.
Therefore, a check must be implemented that compares the number of parameters of a call to the number of arguments of a function def.
Possible alternatives (optional)
No response
Screenshots (optional)
No response
Additional Context (optional)
Functions with star arguments (*args | **kwargs) require special treatment.
The text was updated successfully, but these errors were encountered: