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

Export numeric functions that are in Prelude #81

Open
goldfirere opened this issue May 29, 2014 · 4 comments
Open

Export numeric functions that are in Prelude #81

goldfirere opened this issue May 29, 2014 · 4 comments

Comments

@goldfirere
Copy link
Owner

Things like even, (^), etc. See the export list of Prelude. Make sure to move the definition of (:^) from TypeLits when this is done.

@jstolarek
Copy link
Collaborator

Speaking of even, it is implemented in terms of rem. Do we plan to provide promoted/singletonized Integral type class?

@goldfirere
Copy link
Owner Author

I don't see why not. Contrary to what we wrote in the paper, I believe that overloaded numbers are indeed possible during promotion -- just promote a number literal n to be FromInteger n. My promoted Num class redefines fromInteger to take a Nat, not an Integer, and it seems to work out.

@goldfirere
Copy link
Owner Author

It turns out that doing this would be much easier with match flattening. So this is blocked by #113.

@goldfirere
Copy link
Owner Author

See branch rational.

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

No branches or pull requests

2 participants