3 ms·
> I think Clean Code has encouraged people to write a lot of single line functions that get called from a single place (often with weird parameter lists) as a m
by simoncion 11y ago
> I think Clean Code has encouraged people to write a lot of single line functions that get called from a single place (often with weird parameter lists) as a means of replacing commented code blocks.
Single line functions, called from a single place? To replace commented code blocks?? In the name of improving readability!? What?! (!!!)
Unrelated to that: If your function name correctly and completely describes the actions taken by that function and those that it calls, then replacing a commented code block with that function isn't unreasonable.
shrug I guess the ages old advice: "Dogma is bad. Rules of thumb are often useful." applies to the topics discussed in this subthread. :)