<div dir="auto">I'd say the main reason to implement `append` in GHC would be to handle rules that can't be solved by evaluation (e.g., eliminate append [] on the right, some associativity rule, etc.).<div dir="auto"><br></div><div dir="auto">The speed of evaluation shouldn't really be much different as it should be doing the same thing, more or less.</div><div dir="auto"><br></div><div dir="auto">If there is a big performance hit for just straight evaluation, it might be better to work on that part of GHC, which would also benefit other functions, rather than adding more special cased functions. </div><div dir="auto"><br></div><div dir="auto">Cheers, </div><div dir="auto">Iavor</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 2, 2024, 3:30 PM Hécate via ghc-devs <<a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi GHC devs,<br>
<br>
I was wondering recently, considering that type family evaluation is <br>
notoriously slow, how one would implement type-level list concatenation <br>
directly within GHC in a way that is much less expensive to run. So I am <br>
looking for pointers, as this part of GHC is fairly unknown to me.<br>
<br>
Thinking about it, I'm actually unsure where the tyfam evaluation is <br>
happening.<br>
<br>
Any advice would be appreciated.<br>
<br>
Cheers,<br>
Hécate<br>
<br>
-- <br>
Hécate ✨<br>
🐦: @TechnoEmpress<br>
IRC: Hecate<br>
WWW: <a href="https://glitchbra.in" rel="noreferrer noreferrer" target="_blank">https://glitchbra.in</a><br>
RUN: BSD<br>
<br>
_______________________________________________<br>
ghc-devs mailing list<br>
<a href="mailto:ghc-devs@haskell.org" target="_blank" rel="noreferrer">ghc-devs@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" rel="noreferrer noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
</blockquote></div>