Skip to content

infer type of parameter from super type #1139

@KotlinIsland

Description

@KotlinIsland

Describe the Bug

class A:
    def f(self, i: int):
        ...

class B(A):
    def f(self, i):
        reveal_type(i)  # Unknown, expect int

here the unannotated i can be inferred from the super type as int

Sandbox Link

No response

(Only applicable for extension issues) IDE Information

No response

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions