Skip to content
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

The error message for const Symbol of private identifiers should be better. #30848

Closed
floitschG opened this issue Sep 21, 2017 · 1 comment
Closed
Labels
analyzer-ux area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug

Comments

@floitschG
Copy link
Contributor

Creating private symbols using the const Symbol constructor breaks DDC:

main() {
  print(const Symbol("_foo"));
}

yields the following error:

[error] Evaluation of this constant expression throws an exception.
@floitschG
Copy link
Contributor Author

It seems like this is expected behavior.
Keeping the bug open for a better error message: it should state that private symbols can't be built, unless there is a library-mirror.

@floitschG floitschG added area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. and removed web-dev-compiler labels Sep 21, 2017
@floitschG floitschG changed the title DDC can't handle private symbols The error message for const Symbol of private identifiers should be better. Sep 21, 2017
@bwilkerson bwilkerson added analyzer-ux P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug labels Feb 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyzer-ux area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

2 participants