@@ -693,8 +693,6 @@ s, s = Nums() # E: Incompatible types in assignment (expression has type "int",
693693
694694[case testCovariant]
695695from typing import TypeVar, Generic
696- True = 1
697-
698696T = TypeVar('T', covariant=True)
699697
700698class G(Generic[T]): pass
@@ -708,12 +706,11 @@ c = None # type: G[C]
708706
709707b = a # E: Incompatible types in assignment (expression has type G[A], variable has type G[B])
710708b = c
709+ [builtins fixtures/bool.pyi]
711710[out]
712711
713712[case testContravariant]
714713from typing import TypeVar, Generic
715- True = 1
716-
717714T = TypeVar('T', contravariant=True)
718715
719716class G(Generic[T]): pass
@@ -727,12 +724,11 @@ c = None # type: G[C]
727724
728725b = a
729726b = c # E: Incompatible types in assignment (expression has type G[C], variable has type G[B])
727+ [builtins fixtures/bool.pyi]
730728[out]
731729
732730[case testInvariant]
733731from typing import TypeVar, Generic
734- True = 1
735-
736732T = TypeVar('T') # invariant (default)
737733
738734class G(Generic[T]): pass
@@ -746,4 +742,5 @@ c = None # type: G[C]
746742
747743b = a # E: Incompatible types in assignment (expression has type G[A], variable has type G[B])
748744b = c # E: Incompatible types in assignment (expression has type G[C], variable has type G[B])
745+ [builtins fixtures/bool.pyi]
749746[out]
0 commit comments