LOTUSSCRIPT LANGUAGE
Rewrite the function so that it reaches its base case.
Remove a sufficient number of variable declarations in the procedure to free up stack space by rewriting it as several smaller procedures. If you are using fixed arrays, declare them as dynamic.