void () { runWithLanguageLevel( LanguageLevel.getLatest(), () -> doTestByText(""" from typing import Callable, TypeVar T = TypeVar('T', bound=int) def func(c: Callable[[T], None]): pass def accepts_anything(x: str) -> None: pass func(<warning descr="Expected type '(T) -> None', got '(x: str) -> None' instead">accepts_anything</warning>) """) ); }