void () { runWithLanguageLevel( LanguageLevel.PYTHON36, () -> doTestByText(""" from typing_extensions import Final a: Final[int] = 10 print(a) <warning descr="Already declared name could not be redefined as 'Final'">a</warning>: Final[str] = "10" b = 10 # type: int print(b) <warning descr="Already declared name could not be redefined as 'Final'">b</warning> = "10" # type: Final[str] c: Final[int] = 10 print(c) <warning descr="'c' is 'Final' and could not be reassigned">c</warning>: str = "10\"""") ); }