| library; | 
 | import self as self; | 
 | import "dart:core" as core; | 
 |  | 
 | class A<T extends core::num> extends core::Object { | 
 |   synthetic constructor •() → self::A<self::A::T> | 
 |     : super core::Object::•() | 
 |     ; | 
 |   method foo() → <S extends self::A::T = dynamic>(S) → void { | 
 |     core::print("foo: T = ${self::A::T}"); | 
 |     return <S extends self::A::T>(S a) → void {}; | 
 |   } | 
 | } | 
 | class B<T extends core::num> extends core::Object { | 
 |   synthetic constructor •() → self::B<self::B::T> | 
 |     : super core::Object::•() | 
 |     ; | 
 |   method foo() → (self::B::T) → void { | 
 |     core::print("foo: T = ${self::B::T}"); | 
 |     return (self::B::T a) → void {}; | 
 |   } | 
 | } | 
 | static field self::A<core::num> a = new self::A::•<core::int>(); | 
 | static field self::B<core::num> b = new self::B::•<core::int>(); | 
 | static method main() → dynamic { | 
 |   try { | 
 |     self::a.{self::A::foo}(){() → <S extends core::num = dynamic>(S) → void} as{TypeError,CovarianceCheck} <S extends core::num = dynamic>(S) → void; | 
 |     throw "Expected TypeError"; | 
 |   } | 
 |   on core::TypeError catch(final core::TypeError e) { | 
 |     core::print(e); | 
 |   } | 
 |   try { | 
 |     self::b.{self::B::foo}(){() → (core::num) → void} as{TypeError,CovarianceCheck} (core::num) → void; | 
 |     throw "Expected TypeError"; | 
 |   } | 
 |   on core::TypeError catch(final core::TypeError e) { | 
 |     core::print(e); | 
 |   } | 
 | } |