News for hackers. Stuff that matters.
Re:Why I love Common Lisp and hate Java (2012) by saagarjha on Saturday November 03, 2018 @09:39PM (#18373548)
If I have easy access to a debugger. It’s extra work to hook things up to a debugger, and there are certain restrictions that may apply (attach too late if process launch is not under our control, program may behave differently, etc.). If I do have access to a debugger, often I will just do “printf debugging” there by setting a breakpoint and adding an action to “p someVariable; c”. Usually I treat my debugger a sort of IPython for statically compiled languages, to mess around with and inspect values as programs are executing.
Re:Why I love Common Lisp and hate Java (2012) by sanderjd on Saturday November 03, 2018 @10:58PM (#18373866)
I have yet to come across a situation in which it is not worth the effort to figure out how to attach a debugger to a piece of code I'm modifying.
Re:Why I love Common Lisp and hate Java (2012) by saagarjha on Saturday November 03, 2018 @11:09PM (#18373922)
Again, attaching a debugger is occasionally not helpful–for example, if you're trying to figure out why your program isn't loading certain plugins at launch, you trying to attach the debugger may happen after this step occurs. So you don't get to debug this process.
Re:Why I love Common Lisp and hate Java (2012) by dvlsg on Sunday November 04, 2018 @12:05AM (#18374139)
Or if an issue happens in your staging environment but not locally. That happened to me just yesterday, and a simple print statement gave me the information I needed to resolve the issue.

I probably could have attached a remote debugger, and executed the relevant function a few times until my request got routed to the right process in the cluster, but that honestly would have taken me more time than just committing the print statement and letting CI take it away.

Re:Why I love Common Lisp and hate Java (2012) by sanderjd on Sunday November 04, 2018 @10:04AM (#18376154)
That seems like a good thing to use logging for, instead of a print statement.

But you're right, figuring out a dev / prod discrepancy in already-running code is a case where a debugger is not as useful.

Re:Why I love Common Lisp and hate Java (2012) by candiodari on Sunday November 04, 2018 @04:35AM (#18375048)
Exactly, and in the replies it is really obvious what the debate is really colored by.

In many cases there is no debugger available for someone's favorite platform. And so they "hate debugging". Go programmers, javascript people (where you can't do client->server debugging, but really, really have to), ...

How many Java programmers don't use debuggers ? How many C# developers ? Those languages have excellent debuggers. Python, C/C++, ... decent at best. Go/Javascript/... dismal debugging support.

Re:Why I love Common Lisp and hate Java (2012) by minitech on Sunday November 04, 2018 @05:39AM (#18375232)
> Javascript/... dismal debugging support.

Eh? I thought JavaScript debuggers were pretty good.

Re:Why I love Common Lisp and hate Java (2012) by candiodari on Sunday November 04, 2018 @01:13PM (#18377201)
I always compare my React debugging experience to something like GWT debugging from 5 years back ... and I find it very lacking indeed.