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

Support refined types #39

Open
zainab-ali opened this issue Oct 26, 2017 · 2 comments
Open

Support refined types #39

zainab-ali opened this issue Oct 26, 2017 · 2 comments

Comments

@zainab-ali
Copy link
Contributor

Add support for refined types!

@zainab-ali
Copy link
Contributor Author

I've been taking a bit of a closer look at this. It looks pretty straightforward.

We want to use any of refined's types on Quantity, as long as they can be used on the underlying type.

i.e. if we have evidence for a Validate.Plain[A, F[A]] where F is any type, derive a Validate.Plain[Quantity[A, D], F[Quantity[A, D]].

I think that we can implement the inference rules in the same way.

This should go in a separate libra-refined module.

@zainab-ali
Copy link
Contributor Author

I wonder if it would be good to implement refined based on spire instead? Quantity has spire typeclass instances, so we'd get refined for free.

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

No branches or pull requests

1 participant