blob: 7d3fac5b21616fb9a48c6944cd3c34084bbf64cf [file] [log] [blame]
library test;
import self as self;
import "dart:core" as core;
static method test1() dynamic {
core::List<core::int> x = <core::int>[1, 2, 3];
x.{core::List::add}("hi" as{TypeError} core::int);
x.{core::List::add}(4.0 as{TypeError} core::int);
x.{core::List::add}(4);
core::List<core::num> y = x;
}
static method test2() dynamic {
core::List<core::num> x = <core::num>[1, 2.0, 3];
x.{core::List::add}("hi" as{TypeError} core::num);
x.{core::List::add}(4.0);
core::List<core::int> y = x as{TypeError} core::List<core::int>;
}
static method main() dynamic {}