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 }}
Repository navigation
Adding ParamSpec to an overloaded function causes default parameters to not be considered #5769
f(g) is a correct call, as the first overloading allows arg to be inferred to be the default parameter False, and then P is empty.
Pyrefly gives this error:
ERROR sandbox.py:18: No matching overload found for function `f` called with arguments: (() -> None) [[no-matching-overload](https://pyrefly.org/en/docs/error-kinds/#no-matching-overload)]
Possible overloads:
((ParamSpec(P)) -> None, Literal[False], ParamSpec(P)) -> int | None [closest match]
((ParamSpec(P)) -> None, Literal[True], ParamSpec(P)) -> None
Activity