This repository was archived by the owner on Feb 22, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 26
method closures need binding #44
Comments
another option is a closure wrap like solution: (...args) => obj.method(...args) regardless I think we need to support == operator on these: |
similar TODO that I just noticed: Getter returning a function with a call method, we don't generate the |
also, we may wish to preserve the fact that it was a "dart object", which would lean to the dart.bind approach |
closing for now, but we'll need to revisit identity issues (those should be covered by language tests) |
implementation was 4138cbc |
Closed
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
given
obj.method
in Dart, I suspect DDC currently generatesobj.method
in JS. That won't work. Static codegen should beobj.method.bind(obj)
and dynamic gets will need to handle this as well. Perhaps a helper so we don't have to repeat obj:dart.bind(obj, 'method')
The text was updated successfully, but these errors were encountered: