-
Notifications
You must be signed in to change notification settings - Fork 48
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
sop-core: Concatenate a POP into an NP #176
Comments
This is sibling issue to #115. See general comments there.
|
@phadej I'd also be willing to co-maintain a |
I don't think anymore that But for time being, IMO, they can be defined in EDIT: e.g. |
The problem is that there are so many ways to define even "simple" type families that the hope of actually being able to reuse them is nearly zero. See e.g. the "extra" case in I'm still not extremely fond of adding more things for general-purpose programming to |
I understand that you prefer to add only things to |
I don't have enough experience to comment on that, I would have implemented it in the "vanilla" way, not being aware of particular downsides. |
I needed There isn't |
This may be out of scope, but I use
sop-core
as a lean, clean, principled general purpose library for heterogeneous sums and products. As such it is great, but sometimes I'm lacking a feature. For example, concatenation. For homogeneous lists, there is(++) :: [a] -> [a] -> [a]
andconcat :: [[a]] -> [a]
, but I believe this doesn't exist insop-core
. I think it should be possible to implement with these type signatures:Maybe it's already possible to do this with the existing type families, if so, I don't know how. In that case it might be helpful to add a type alias and a function to witness this.
Either way, if you think this works and is a good addition, I'll happily send a PR.
The text was updated successfully, but these errors were encountered: