Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Provide All Alternate Number Formats regardless of Enabled Language Extensions #2772

Closed
drsooch opened this issue Mar 10, 2022 · 1 comment · Fixed by #2790
Closed

Provide All Alternate Number Formats regardless of Enabled Language Extensions #2772

drsooch opened this issue Mar 10, 2022 · 1 comment · Fixed by #2790

Comments

@drsooch
Copy link
Collaborator

drsooch commented Mar 10, 2022

Currently, the alternate number format plugin only suggests formats when the Language Extension is enabled.

So for example, with Haskell2010 set as the default language, the literal 15 will provide 0xF and 0o17 as alternatives.

With BinaryLiterals enabled the literal 15 will provide 0xF, 0o17, and 0b1111.

Instead the provided alternatives should span all possible formats and add the language extension if not already enabled.

@michaelpj
Copy link
Collaborator

Maybe we can include a note in the code action title when we need an extension, "Convert to 0xF (needs BinaryLiterals)" or something.

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants