blob: 2e9f7aa10dfcd7692c8ebd1b8711239606ce16d2 [file] [log] [blame]
library test;
//
// Problems in library:
//
// pkg/front_end/testcases/inference_new/dependency_only_if_generic_method.dart:18:5: Error: Can't infer the type of 'b': circularity found during type inference.
// Specify the type explicitly.
// var b = /*@returnType=() -> invalid-type*/ () =>
// ^
//
import self as self;
import "dart:core" as core;
class A extends core::Object {
synthetic constructor •() self::A
: super core::Object::•()
;
method f<T extends core::Object = dynamic>(self::A::f::T t) self::A::f::T
return t;
method g(dynamic i) core::int
return 0;
}
static field self::A a = new self::A::•();
static field invalid-type b = (() () invalid-type => self::a.{self::A::f}<() invalid-type>(self::c)) as{TypeError} invalid-type;
static field () invalid-type c = () invalid-type => self::a.{self::A::f}<invalid-type>(self::b);
static field () () core::int d = () () core::int => self::a.{self::A::f}<() core::int>(self::e);
static field () core::int e = () core::int => self::a.{self::A::g}(self::d);
static method main() dynamic {}