Skip to content

Remove reflect constant value #10754

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

Closed

Conversation

nicolasstucki
Copy link
Contributor

To use this we usually need to use an asInstanceOf which cannot be checked in the case of ClassOf. Doing so without being careful will introduce an unsoundness. It seems better to remove this method and let users match all the cases.

In the future, we could reintroduce a restricted version of this API that only works on a subset of the constants.

Based on #10753

@nicolasstucki nicolasstucki self-assigned this Dec 11, 2020
We can either print the structure with the pattern or the code like representation of the value.
To use this we usually need to use an `asInstanceOf` which cannot be checked in the case of ClassOf. Doing so without being careful will introduce an unsoundness. It seems better to remove this method and let users match all the cases.

In the future, we could reintroduce a restricted version of this API that only works on a subset of the constants.
@nicolasstucki nicolasstucki force-pushed the remove-reflect-constant-value branch from eee9fa8 to 9afc750 Compare December 11, 2020 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant