-
Notifications
You must be signed in to change notification settings - Fork 116
Open
Labels
bugSomething isn't workingSomething isn't workingcallsIssues relating to call-signature checking and diagnosticsIssues relating to call-signature checking and diagnostics
Milestone
Description
Status:
- support single-starred arguments
- support single-starred arguments in calls to overloaded functions
- support double-starred arguments
Original description:
Summary
Minimal reproducer:
def foo(initial_arg: str, *args: str) -> None:
...
foo(*["a", "b", "c"]) # No argument provided for required parameter `initial_arg` of function `foo` (lint:missing-argument) [Ln 4, Col 1]
foo(*[1, "a", "b"]) # No argument provided for required parameter `initial_arg` of function `foo` (lint:missing-argument) [Ln 4, Col 1]
https://play.ty.dev/4b8dc795-03b5-4fbf-a5c3-639f9518e093
I'd expect first the invocation to type check because the splatted args have compatible types to cover both the first argument and the var args.
corrylc, rosborn, j178, toppk, SoftwareApe and 27 more
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingcallsIssues relating to call-signature checking and diagnosticsIssues relating to call-signature checking and diagnostics