characterization of subset of Monads that respect tail calls?

Carter Schonwald carter.schonwald at gmail.com
Tue Sep 27 15:07:52 UTC 2022


Hey Isaac,
thats certainly an interesting approach, it seems like that solves it by
reframing the question as "can you implement a loop/trampoline in the
monad". It would be even cooler to have an approach that does proper tail
calls i think ..


On Mon, Sep 26, 2022 at 8:15 PM Isaac Elliott <isaace71295 at gmail.com> wrote:

>
> https://pursuit.purescript.org/packages/purescript-tailrec/6.1.0/docs/Control.Monad.Rec.Class
> seems like a good starting point
>
> On Tue, 27 Sept 2022, 6:39 am Carter Schonwald, <
> carter.schonwald at gmail.com> wrote:
>
>> Hello everyone!
>> a recent conversation I has having led to an interesting question: is
>> there a good interface or something for Monads which guarantee tail calls
>> are tail calls? (ideally via a stronger api assumption for tail position
>> computations in a monad rather than "trustme" style api contracts)
>>
>> thx
>> -Carter
>> _______________________________________________
>> Libraries mailing list
>> Libraries at haskell.org
>> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20220927/1ca84932/attachment.html>


More information about the Libraries mailing list