blob: 3de016990f67054dcf142540dcb73f06f7df8ab3 [file] [log] [blame]
library test;
//
// Problems in library:
//
// pkg/front_end/testcases/inference_new/field_inference_circularity.dart:12:7: Error: Can't infer the type of 'x': circularity found during type inference.
// Specify the type explicitly.
// var x = /*@returnType=invalid-type*/ () => new B(). /*@target=B::x*/ x;
// ^
//
import self as self;
import "dart:core" as core;
class A extends core::Object {
field invalid-type x = (() invalid-type => new self::B::•().{self::B::x}) as{TypeError} invalid-type;
field () →* invalid-type y = () invalid-type => new self::B::•().{self::B::x};
synthetic constructor •() self::A*
: super core::Object::•()
;
}
class B extends self::A {
field invalid-type x = null;
field () →* invalid-type y = null;
synthetic constructor •() self::B*
: super self::A::•()
;
}
static method main() dynamic {}