blob: 2092b43db9b0ad2dc850924a537cb05cb0cd26c0 [file] [log] [blame]
library test;
import self as self;
import "dart:core" as core;
abstract class I<T extends core::Object = dynamic> extends core::Object {
synthetic constructor •() self::I<self::I::T>
: super core::Object::•()
;
abstract method f1(generic-covariant-impl self::I::T x) void;
abstract method f2(generic-covariant-impl self::I::T x) void;
}
class C<U extends core::Object = dynamic> extends core::Object implements self::I<core::int> {
synthetic constructor •() self::C<self::C::U>
: super core::Object::•()
;
method f1(generic-covariant-impl core::int x) void {}
method f2(generic-covariant-impl core::int x, [generic-covariant-impl self::C::U y = null]) void {}
}
class D<U extends core::Object = dynamic> extends self::C<self::D::U> {
synthetic constructor •() self::D<self::D::U>
: super self::C::•()
;
method f1(generic-covariant-impl core::int x) void {}
method f2(generic-covariant-impl core::int x, [generic-covariant-impl self::D::U y = null]) void {}
}
static method g1(self::C<core::num> c) void {
c.f1(1);
}
static method g2(self::I<core::num> i) void {
i.f1(1.5);
}
static method g3(self::C<core::num> c) void {
c.f2(1, 1.5);
}
static method g4(self::D<core::num> d) void {
d.f1(1);
}
static method g5(self::D<core::num> d) void {
d.f2(1, 1.5);
}
static method test() void {
self::g2(new self::C::•<core::num>());
}
static method main() void {}