3 ms·
If working in a solitary codebase, this problem isn't very interesting. Do whatever makes your life easier. If you're working on any kind of code that serves
by linuxftw 3y ago
If working in a solitary codebase, this problem isn't very interesting. Do whatever makes your life easier.
If you're working on any kind of code that serves as a library to other code, don't mutate the signatures of your public methods/functions. Once that signature is released, the only changes to it's output should be bug fixes. If you have a need for two very similar functions, you should use 2 wrapper functions with the common code in the 3rd.