[m-users.] Tail recursion optimisation
Julien Fischer
jfischer at opturion.com
Mon May 18 15:32:18 AEST 2026
On Mon, 18 May 2026 at 00:15, Volker Wysk <post at volker-wysk.de> wrote:
>
>
> I have two mutually recursive predicates, which really need the tail
> recursion optimisation. Does this recursion also happen when there are two
> or more predicates involved? They both are clearly tail recursive, calling
> each other.
Yes, if the predicates in question are mutually tail recursive and are
all defined
in the same module. (If they are defined in different modules, then
it will depend
on what cross module inlining takes place.)
Julien.
>
> Cheers,
> Volker
> _______________________________________________
> users mailing list
> users at lists.mercurylang.org
> https://lists.mercurylang.org/listinfo/users
More information about the users
mailing list