Skip to content

Ruff fails to detect duplicate type parameter names #11119

@JelleZijlstra

Description

@JelleZijlstra

This is a SyntaxError:

>>> type X[T, T] = int
  File "<stdin>-0", line 1
SyntaxError: duplicate type parameter 'T'

But Ruff is fine with it. Similar to #11118.

Metadata

Metadata

Assignees

No one assigned

    Labels

    linterRelated to the linterruleImplementing or modifying a lint rule

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions