Function "modes" vs. separate functions
bahamutzero8825 at gmail.com
Fri Jul 29 22:28:26 EDT 2011
On 2011.07.29 08:57 PM, Ben Finney wrote:
> If they share a lot of code, either it *is* separable to common
> functions (in which case, implement it that way), or the “same thing”
> code is sufficiently complex that it's better to show it explicitly.
> But this is all getting rather generic and abstract. What specific
> real-world examples do you have in mind?
I can't come up with any off the top of my head. I was thinking of a
general rule anyway; ultimately one decides (or at least should) how to
write code on a case-by-case basis.
CPython 3.2.1 | Windows NT 6.1.7601.17592 | Thunderbird 5.0
PGP/GPG Public Key ID: 0xF88E034060A78FCB
More information about the Python-list