testTailRecursion

abstract fun testTailRecursion()

Tests that, with it.unibo.tuprolog.solve.flags.LastCallOptimization on, a 100-deep tail-recursive recursive/1 predicate that eventually throws leaves only 2 frames (the throwing goal and the top-level query) in the resulting Solution.Halt's logic stack trace, since tail calls do not accumulate stack frames.