3 ms·
> I'm adverse to debuggers as i've more than once caught myself following a rabbit hole of steping through code instead of thinking. Yes. I was kind of forced
by astrobe_ 4y ago
> I'm adverse to debuggers as i've more than once caught myself following a rabbit hole of steping through code instead of thinking.
Yes. I was kind of forced to think and do printf debugging at the beginning of my career, after having used before that (as a hobbyist) quite good asm debuggers.
Maybe that's just me, but I also was, I believe, a bit over-reliant on the debugger - I would just compile, run, see what happen, and launch the debugger if something didn't work.
Nowadays I could use sometimes a debugger - but the system I work with is sort of soft real-time so stopping at a breakpoint of even slight changes in timings can change the context - in some cases even printf debugging could make a bug vanish.
If nothing else, debugging without a debugger is a good exercise in logically thinking - and it can save time too.
- Gibbon1 4y agoI have a code base that is a mix of hard, soft, and static real time. I have a command line interface built in to it and a lot debug logging that can be re-enabled. I've also spent some effort into making it tolerate being interrupted. And there is also the good old technique of inserting break points while the code is running.