Comment by LandR

1 month ago

I've experienced this watching a coworker debugging that sort of code, he had initially written it all as a long chained statements, then had to undo it all to allow him to debug. Once it was extracted it could be debugged and step through it, great!

Once he was done debugging it he put it all back to how it was originally...

The mind boggles.

Looks like a limited debugger unable to let inspect what's happening in each chained function. Or is that something else?

I mean, it looks like the same level as adding explicit temporary variable because the debugger won't give provide values of the different part of an expression assigned to a third variable. That's a way to circumvent the tool limitation, just as you can add a tap or map in a middle of a chain if the debugger is too rudimentary to provide more conveniency.