| library test /*isNonNullableByDefault*/; |
| // |
| // Problems in library: |
| // |
| // pkg/front_end/testcases/inference/conflicts_can_happen2.dart:34:7: Error: Can't infer a return type for 'a' as the overridden members don't have a combined signature. |
| // Try adding an explicit type. |
| // get a => throw ''; |
| // ^ |
| // pkg/front_end/testcases/inference/conflicts_can_happen2.dart:22:12: Context: This is one of the overridden members. |
| // final I1 a = throw ''; |
| // ^ |
| // pkg/front_end/testcases/inference/conflicts_can_happen2.dart:26:12: Context: This is one of the overridden members. |
| // final I2 a = throw ''; |
| // ^ |
| // |
| import self as self; |
| import "dart:core" as core; |
| |
| class I1 extends core::Object { |
| field core::int x = 0; |
| synthetic constructor •() → self::I1 |
| : super core::Object::•() |
| ; |
| } |
| class I2 extends core::Object { |
| field core::int y = 0; |
| synthetic constructor •() → self::I2 |
| : super core::Object::•() |
| ; |
| } |
| class I3 extends core::Object implements self::I1, self::I2 { |
| field core::int x = 0; |
| field core::int y = 0; |
| synthetic constructor •() → self::I3 |
| : super core::Object::•() |
| ; |
| } |
| class A extends core::Object { |
| final field self::I1 a = throw ""; |
| synthetic constructor •() → self::A |
| : super core::Object::•() |
| ; |
| } |
| class B extends core::Object { |
| final field self::I2 a = throw ""; |
| synthetic constructor •() → self::B |
| : super core::Object::•() |
| ; |
| } |
| class C1 extends core::Object implements self::A, self::B { |
| synthetic constructor •() → self::C1 |
| : super core::Object::•() |
| ; |
| get a() → self::I3 |
| return throw ""; |
| } |
| class C2 extends core::Object implements self::A, self::B { |
| synthetic constructor •() → self::C2 |
| : super core::Object::•() |
| ; |
| get a() → invalid-type |
| return throw ""; |
| } |
| static method main() → dynamic {} |