ruff
68895188 - [ty] Add "Did you mean" suggestion for Callable[[...], R]

Commit
4 hours ago
[ty] Add "Did you mean" suggestion for Callable[[...], R] When `...` is the sole element inside the parameter list of a `Callable` type (i.e. `Callable[[...], int]`), add a subdiagnostic suggesting the correct gradual form: `Callable[..., <return type>]`. This is the only ellipsis-in-type-expression case where the user's intent is unambiguous enough to warrant a suggestion. Other cases (e.g. `Callable[[int, ...], R]`, `Union[int, ...]`, `list[...]`) are left without suggestions since the intended type is unclear. https://claude.ai/code/session_01KDdJ3EZbcBiVeEADaLjPdy
Author
Parents
Loading