Stack Overflow isn’t just a software Q & A site

! Warning: this post hasn't been updated in over three years and so may contain out of date information.

Back in the days when Commodore were able to advertise 64K of memory as being synonymous with the large memory of an elephant, stack overflow errors were common. With limited memory, only a small amount could be spared for the stack, and a series of function calls could easily fill it up.

These days, when computers have 5-6 orders of magnitude more memory, the concept of a stack overflow has been relegated to an in-joke name for an excellent developer Q & A site. I was therefore more than a little surprised when a Flex app produced the following stack trace:

Scrolling down through the stack trace, everything that came after what I’ve copied above was just many references to the one method. I’d written a recursive method who’s test for the end of the recurse would always fail, so it had gone into an “infinite loop”. It just goes to show, no matter how much memory you have, a run-away recursive method will always run out of stack space. Stack overflow errors still exist, they are simply hidden away from all but sloopy recursion junkies… 🙂