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

Offer opaque ways to use equality #8

Open
treeowl opened this issue Nov 11, 2016 · 4 comments
Open

Offer opaque ways to use equality #8

treeowl opened this issue Nov 11, 2016 · 4 comments

Comments

@treeowl
Copy link

treeowl commented Nov 11, 2016

As far as I can tell, the library doesn't currently offer fully general ways to eliminate equality without leaning on GHC's fancy equality constraint propagation. The bare-bones basic function is

-- | Eliminate equality evidence
useEq :: a :~: b -> f a -> f b
useEq Refl x = x
@treeowl treeowl changed the title Offer opaque ways to build and use equality Offer opaque ways to use equality Nov 11, 2016
@treeowl
Copy link
Author

treeowl commented Nov 11, 2016

I've edited the description above because I realized one piece was silly.

@glaebhoerl
Copy link
Owner

This library has been essentially superseded by the Data.Type.Equality module in base, so maybe that would be a better place to add this?

For the record, what's the use case?

@treeowl
Copy link
Author

treeowl commented Nov 11, 2016

Completeness, mostly. But someone could choose to restrict themselves,
avoiding gcastWith, and therefore limit their language extension support
needs to Rank2Types.

On Nov 11, 2016 5:34 AM, "Gábor Lehel" notifications@github.com wrote:

This library has been essentially superseded by the Data.Type.Equality
https://hackage.haskell.org/package/base-4.9.0.0/docs/Data-Type-Equality.html
module in base, so maybe that would be a better place to add this?

For the record, what's the use case?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#8 (comment),
or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABzi_VDCxUEXuWuNYpUTOzopO-NItSiAks5q9ESdgaJpZM4KvXN4
.

@glaebhoerl
Copy link
Owner

I don't maintain this any more in any case, but I'd be happy to give you commit access if you want it.

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

2 participants