Methods should be able to override function-typed getters #15108
Labels
area-language
Dart language related items (some items might be better tracked at github.com/dart-lang/language).
closed-not-planned
Closed as we don't intend to take action on the reported issue
type-enhancement
A request for a change that isn't a bug
Consider the following code:
typedef void ZeroArgumentFunction();
abstract class Parent {
ZeroArgumentFunction get fn;
}
class Child extends Parent {
void fn() => print("hello");
}
Currently, this prints an error because [Child.fn] conflicts with [Parent.fn], despite the fact that "child.fn" will return a ZeroArgumentFunction.
This makes [ZoneSpecification] particularly difficult to work with, since it declares numerous getters that return functions.
The text was updated successfully, but these errors were encountered: