| library test; |
| import self as self; |
| import "dart:core" as core; |
| |
| class B extends core::Object { |
| field core::Object* _x = null; |
| synthetic constructor •() → self::B* |
| : super core::Object::•() |
| ; |
| method f([core::num* x = #C1]) → void { |
| this.{self::B::_x} = x; |
| } |
| method g({core::num* x = #C2}) → void { |
| this.{self::B::_x} = x; |
| } |
| method check(core::Object* expectedValue) → void { |
| if(!this.{self::B::_x}.==(expectedValue)) { |
| throw "Expected _x == ${expectedValue}; got ${this.{self::B::_x}}"; |
| } |
| } |
| } |
| abstract class I<T extends core::Object* = dynamic> extends core::Object { |
| synthetic constructor •() → self::I<self::I::T*>* |
| : super core::Object::•() |
| ; |
| abstract method f([generic-covariant-impl self::I::T* x = #C3]) → void; |
| abstract method g({generic-covariant-impl self::I::T* x = #C3}) → void; |
| } |
| class C extends self::B implements self::I<core::num*> { |
| synthetic constructor •() → self::C* |
| : super self::B::•() |
| ; |
| forwarding-stub method f([generic-covariant-impl core::num* x = #C1]) → void |
| return super.{self::B::f}(x); |
| forwarding-stub method g({generic-covariant-impl core::num* x = #C2}) → void |
| return super.{self::B::g}(x: x); |
| } |
| static method main() → dynamic { |
| self::C* c = new self::C::•(); |
| c.f(); |
| c.check(10); |
| c.g(); |
| c.check(20); |
| } |
| |
| constants { |
| #C1 = 10 |
| #C2 = 20 |
| #C3 = null |
| } |