| library /*isNonNullableByDefault*/; |
| // |
| // Problems in library: |
| // |
| // pkg/front_end/testcases/general/issue37776.dart:11:7: Error: 'X' is already declared in this scope. |
| // class X { |
| // ^ |
| // pkg/front_end/testcases/general/issue37776.dart:7:7: Context: Previous declaration of 'X'. |
| // class X { |
| // ^ |
| // |
| // pkg/front_end/testcases/general/issue37776.dart:16:9: Error: Couldn't find constructor 'X.foo'. |
| // const X.foo(); |
| // ^^^ |
| // |
| import self as self; |
| import "dart:core" as core; |
| |
| class X#1 extends core::Object /*hasConstConstructor*/ { |
| const constructor foo() → self::X#1 |
| : super core::Object::•() |
| ; |
| } |
| class X extends core::Object /*hasConstConstructor*/ { |
| const constructor foo() → self::X |
| : super core::Object::•() |
| ; |
| } |
| static method main() → void { |
| invalid-expression "pkg/front_end/testcases/general/issue37776.dart:16:9: Error: Couldn't find constructor 'X.foo'. |
| const X.foo(); |
| ^^^"; |
| } |