Dozer Posted January 13, 2013 Report Share Posted January 13, 2013 I found this guide to recursion quite informative. It really is an iaiarea of programming where the programmer must tread carefully. http://www.bobhobbs.com/files/kr_lovecraft.html Quote Link to comment Share on other sites More sharing options...
Keith Smith Posted January 13, 2013 Report Share Posted January 13, 2013 one of my favorite recursive acronyms, a mail reader called PINE. it stands for "PINE is Not Elm" I use recursion fairly heavily when writing XSLT style sheets for handling XML data, but not as much in the OO languages. It can produce fairly elegant code, though, when properly authored. Quote Link to comment Share on other sites More sharing options...
PhM Posted February 9, 2013 Report Share Posted February 9, 2013 It really is an area of programming where the programmer must tread carefully.Indeed, the biggest danger being a stack overflow. This is not something PC developers are aware of as the default stack is rather big. But stack overflow may very well bite you if you have to port your perfectly working and elegant program on some other platforms. If you need to port on such platforms and chose to stick with recursion you will then have to make sure any input data that your program will have to deal with will never ever overflow the stack no matter where the stack pointer is a the time your recursive program is called. This means things like checking all code paths, size of arguments passed on stack and all local variables in each of these code paths. Having to develop on several platforms, recursion is something I stay away from, too much potential trouble. PhM 1 Quote Link to comment Share on other sites More sharing options...
Dozer Posted February 10, 2013 Author Report Share Posted February 10, 2013 Did you read the linked article PhM I have a confession. I know what recursion is, but my programming isn't at a level where I can identify when it's a good or bad time to use it. I just enjoyed the conflation of Lovecraft and recursion. Quote Link to comment Share on other sites More sharing options...
chris k Posted February 11, 2013 Report Share Posted February 11, 2013 10 PRINT "This program will crash in....."20 GOSUB 1030 END Quote Link to comment Share on other sites More sharing options...
PhM Posted March 10, 2013 Report Share Posted March 10, 2013 Did you read the linked article PhM Yes. And as this is about plugin development, in other words programming, I thought that someone might end up here while looking for what recursion is all about. Given the fact that your comment : "It really is an area of programming where the programmer must tread carefully." was totally appropriate I decided to add some facts to help understand why it is not a good thing to do. In short : Nice and fun in academic discussions, too risky in real life. PhM 1 Quote Link to comment Share on other sites More sharing options...
Dozer Posted March 11, 2013 Author Report Share Posted March 11, 2013 Nice and fun in academic discussions, too risky in real life.Actually you misquoted me: I said it's an iaiarea where programmers must tread carefully. More serious than writing bad code, they risk awakening the Old Ones... wait... did you hear that? They're coming! They're here! Ia! Ia! Cthulhu fhtagn! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.