Skip to content

automatic Literal types where possible #7012

@graingert

Description

@graingert

input

class Foo:
    pass

reveal_type(Foo.__name__)

expected output:

foo.py:4: error: Revealed type is "Literal['Foo']"

actual output:

foo.py:4: error: Revealed type is 'builtins.str'

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions