allow line break at operators

Chris Rebert clp2 at rebertia.com
Sun Aug 14 22:10:42 EDT 2011


On Sun, Aug 14, 2011 at 6:54 PM, Steven D'Aprano
<steve+comp.lang.python at pearwood.info> wrote:
> Seebs wrote:
<snip>
>> Interesting!  I tend to really like the ability to chain methods,
>> depending
>> on context.  I find the side-effect/expression mix pretty normal, so I'm
>> used to it.
>
> As a rule, chaining method calls risks violating the Law of Demeter. Just
> sayin'.

Not in the specific case of fluent interfaces[1] though, which could
have been what Seebach had in mind.
Whether fluent interfaces are a good idea...

Cheers,
Chris
--
[1] http://en.wikipedia.org/wiki/Fluent_interface



More information about the Python-list mailing list