Ask HN: Why is output still popular in debugging?
1–6 of 6 posts
Re: Ask HN: Why is output still popular in debugging?
#2I don't see IDEs as much help here because Drupal is so dynamic there's no easy way to jump through all the function/method calls that are useless calls to step through -- it's just easier to narrow down the debugging surface with well placed output messages.
Please someone point me at way to have the "setup" point me to the errors, and not me telling her debugger where I think the error is with a breakpoint...
Re: Ask HN: Why is output still popular in debugging?
#3Re: Ask HN: Why is output still popular in debugging?
#4Different benefits come from each approach. Printing stuff out means you get a record of what happened during program execution, which you can compare to what you expect to have happened. With breakpoints, you have to keep track in your head, not only of where you are, but of where you expect to be. They can be useful too, but I probably use print statements about ten times as often.
Thanks for putting this so clearly. That is the headache with breakpoints in complicated systems with lots of layers of indirection.
Re: Ask HN: Why is output still popular in debugging?
#5The interim output debug message is the one method that is always available in whatever environment one happens to be programming in. When there is no debugger available, one could not use "the debugger" even if one wanted to do so.
Also, your statement presupposes that one is using an IDE. Some of us programmers out here despise all IDE's and never, ever, program with an IDE, ever. When there is no IDE, there is no "debugger ... integrated in the IDE".