blob: ef441c3d1316e579997786a2ef7d038210aa42c4 [file] [log] [blame]
library test /*isNonNullableByDefault*/;
//
// 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;
// ^
//
// pkg/front_end/testcases/inference_new/field_inference_circularity.dart:18:7: Error: Field 'y' should be initialized because its type 'invalid-type Function()' doesn't allow null.
// var y;
// ^
//
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}{invalid-type};
field () invalid-type y = () invalid-type => new self::B::•().{self::B::x}{invalid-type};
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 {}