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

Add compile-time check for terminating decimal #27

Open
chshersh opened this issue May 29, 2019 · 3 comments
Open

Add compile-time check for terminating decimal #27

chshersh opened this issue May 29, 2019 · 3 comments
Labels
type-magic Type families, type-level numbers

Comments

@chshersh
Copy link
Contributor

See this comment:

TODO: check this statically

@chshersh chshersh added the type-magic Type families, type-level numbers label May 29, 2019
@yigitozkavci
Copy link

Hi @chshersh,

Would you be able to confirm whether this is still an issue?
This TODO in the code no longer exists and I've failed to reproduce the mentioned "hanging showMemory".

@chshersh
Copy link
Contributor Author

chshersh commented Oct 1, 2019

@yigitozkavci Sure, this is still an issue. Well, more like a feature. TODO is removed from a code because we convert TODOs in code to GitHub issues.

You can reproduce like this in ghci:

ghci> type instance UnitSymbol 7000 = "invalid"
ghci> showMemory (toMemory @7000  $ bit 4)

The output of the last command will be an infinite string. But what we want is a compile-time error with good error message in such cases.

@yigitozkavci
Copy link

Thank you, I'm on it then :)

yigitozkavci added a commit to yigitozkavci/membrain that referenced this issue Oct 1, 2019
yigitozkavci added a commit to yigitozkavci/membrain that referenced this issue Oct 1, 2019
@vrom911 vrom911 added the Hacktoberfest https://hacktoberfest.digitalocean.com/ label Oct 2, 2019
@chshersh chshersh removed the Hacktoberfest https://hacktoberfest.digitalocean.com/ label Oct 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-magic Type families, type-level numbers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants