Skip to content

Fix support of var-positional parameter in Argument Clinic #122688

Open
@serhiy-storchaka

Description

@serhiy-storchaka

Currently Argument Clinic with a var-positional parameter is only used in few functions (print(), the TypeVar constructor (see #118814) and several set methods), so this is not well tested.

There are several bugs here:

  • Keyword-only parameters after the var-positional parameter are marked as positional-or-keyword parameters.
  • The number of required arguments for keyword-only parameters was calculated incorrectly.
  • Some invalid combination of the var-positional parameter with /, * and deprecation markers are not forbidden or produce unrelated errors.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions