Get a hold of getter/setter function #13389
Labels
area-language
Dart language related items (some items might be better tracked at github.com/dart-lang/language).
type-enhancement
A request for a change that isn't a bug
This issue was originally filed by Misko.H...@gmail.com
class Foo {
String _foo;
get foo() => _foo;
method() => null;
}
I can closures a method like this
Function method = (new Foo()).method;
This allows me to pass the method closure into callbacks of other API. It is equally useful to pass closure for getter or setter functions. But there is no way to closures the getter/setter. The following code snippet returns a value rather then closurized function.
(new Foo()).method; // returns value rather then function closure which returns a value
Perhaps some other syntax by which I could get a hold of the getter/setter?
The text was updated successfully, but these errors were encountered: