Closed jonathanhogg closed 6 months ago
Swapping the if
around so that the recursive call comes in the else
expression fixes the problem, but perhaps this is a sign that the simplifier should be smarter about not trying to evaluate expressions it doesn't need to.
Flitter does not support recursion.
That said, you can of course make it recurse with this one hack:
Sadly this will cause the simplifier to explode because it attempts to statically evaluate this recursion. The implementation of
tree.IfElse.simplify()
eagerly evaluates the then expression of theif
and chokes on its own stack.