blob: 1066ec87db641076cad2d84d94232fdd146c13d1 [file] [log] [blame]
library /*isNonNullableByDefault*/;
//
// Problems in library:
//
// pkg/front_end/testcases/extensions/issue44844.dart:7:8: Error: 'foo' is already declared in this scope.
// void foo() {}
// ^^^
// pkg/front_end/testcases/extensions/issue44844.dart:6:14: Context: Previous declaration of 'foo'.
// static int foo = 2;
// ^^^
//
// pkg/front_end/testcases/extensions/issue44844.dart:11:5: Error: The method 'foo' isn't defined for the class 'int'.
// Try correcting the name to the name of an existing method, or defining a method named 'foo'.
// 3.foo();
// ^^^
//
import self as self;
import "dart:core" as core;
extension _extension#0 on core::int {
static field foo = self::_extension#0|foo;
}
static field core::int _extension#0|foo;
static method test() void {
invalid-expression "pkg/front_end/testcases/extensions/issue44844.dart:11:5: Error: The method 'foo' isn't defined for the class 'int'.
Try correcting the name to the name of an existing method, or defining a method named 'foo'.
3.foo();
^^^" in 3{<unresolved>}.foo();
}
static method main() dynamic {}