blob: c0d45fcab4fef2ff4d54973df2fe98ecccdccbc3 [file] [log] [blame]
library;
import self as self;
import "dart:core" as core;
class C<T extends core::Object> extends core::Object {
field dynamic v = MakeClosure<(dynamic) dynamic>(self::closure#C#v#function, null);
final field dynamic y = MakeClosure<() dynamic>(self::closure#C#y#function, null);
static final field dynamic z = MakeClosure<() dynamic>(self::closure#C#z#function, null);
constructor •() void
: super core::Object::•()
;
}
static field dynamic x = MakeClosure<() dynamic>(self::closure#x#function, null);
static method main() dynamic {
if(!new self::C::•<core::String>().v(""))
throw "C<String>.v false on String";
if(new self::C::•<core::String>().v(0))
throw "C<String>.v true on int";
if(new self::C::•<core::String>().v(null))
throw "C<String>.v true on null";
if(new self::C::•<core::int>().v(""))
throw "C<int>.v true on String";
if(!new self::C::•<core::int>().v(0))
throw "C<int>.v false on int";
if(new self::C::•<core::int>().v(null))
throw "C<int>.v true on null";
if(!"x".==(self::x.call()))
throw "x";
if(!"y".==(new self::C::•<core::String>().y()))
throw "y";
if(!"z".==(self::C::z.call()))
throw "z";
}
static method closure#C#v#function(Vector #contextParameter, dynamic x) → dynamic {
return x is dynamic;
}
static method closure#C#y#function(Vector #contextParameter) → dynamic {
return "y";
}
static method closure#C#z#function(Vector #contextParameter) → dynamic {
return "z";
}
static method closure#x#function(Vector #contextParameter) → dynamic {
return "x";
}