Use a fake GADT for sequence folds and traversals#1078
Use a fake GADT for sequence folds and traversals#1078treeowl wants to merge 6 commits intohaskell:masterfrom
Conversation
|
As promised, here's the working draft. It's incomplete and completely unbenchmarked. |
| size (Single x) = size x | ||
| size (Deep v _ _ _) = v | ||
|
|
||
| -- We don't fold FingerTrees directly, but instead coerce them to |
There was a problem hiding this comment.
This is a lie at the moment. It might or might not be true later. WIP....
|
@augustss I'm sure this code is nonsense under MicroHs, but the error message it gives me looks equally nonsensical. |
|
If GHC doesn't complain then MicroHs shouldn't either. I'm happy to take a
bug report.
…On Sun, Dec 15, 2024, 05:26 David Feuer ***@***.***> wrote:
@augustss <https://github.com/augustss> I'm sure this code is nonsense
under MicroHs, but the error message it gives me looks equally nonsensical.
—
Reply to this email directly, view it on GitHub
<#1078 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABIARHTII3IMPFIWVETMHG32FUAFXAVCNFSM6AAAAABTUEXLAGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNBTGQ2DENZYHE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
|
It's not just MicroHs, I've never seen GHC react in this many ways to the same piece of code 😀
|
Use in more functions, etc.
|
This still isn't benchmarked, but it's much closer to complete. The main thing I haven't tried applying it to is |
|
@meooow25 Do you have any general thoughts? |
209374c to
8865b01
Compare
b89264c to
95b26ed
Compare
|
Hmm.... Benchmarks are not working out at all. I don't yet know what goes wrong. |
I haven't seen all of it, but the implementations look alright.
I'm not sure what you mean. For me tests and benchmarks seem to be running fine.
This is not a problem today since it is just the coerced Regarding the slightly bad |
No description provided.