New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dart2js Symbol and/or mirrors issue #11833
Comments
This comment was originally written by fra...@igindo.com Actually, come to think of it, the above example allows me to access library private members via mirrors in the DartVM, not sure if this is as designed? All properties I'm trying to set via instanceMirrors.setField are in fact private (underscored) |
This comment was originally written by fra...@igindo.com Update, I made the properties public, and then I get no crash in Dart2JS, |
Added Area-Dart2JS, Triaged labels. |
There is no security leak in the Dart VM. Privacy in Dart is not a security mechanism. You're supposed to be able to access private members using reflection, however, private symbols is a bit messed up at this time. Both in dart2js and in the VM. |
Set owner to @peter-ahe-google. |
Marked this as blocking #6490. |
Added this to the M7 milestone. |
Removed Priority-Unassigned label. |
Removed this from the 1.6 milestone. |
Removed Oldschool-Milestone-1.6 label. |
closing this issue as a duplicate, since the main thing is to support privates in dart:mirrors, we also have #13597 to track that. |
This issue was originally filed by fra...@igindo.com
What steps will reproduce the problem?
Then JS crashes saying: Caught NoSuchMethodError : method not found: '_liblib10$_name='
Works fine in DartVM, crashes Dart2JS
Note, at no point did I create the Symbol via code, I did reflection on the extended class type, and the super class, and joined the 2 result lists to group both the super classes properties and subclasses properties in one List. Then loop the list to set properties at runtime to all properties of the extended class instance.
The text was updated successfully, but these errors were encountered: