allow line break at operators

Chris Angelico rosuav at gmail.com
Thu Aug 11 00:42:06 CEST 2011


On Wed, Aug 10, 2011 at 10:51 PM, Ben Finney <ben+python at benfinney.id.au> wrote:
> Seebs <usenet-nospam at seebs.net> writes:
>> I've seen bits of code in preprocessing-based "Python with {}" type
>> things, and they still look like Python to me, only they favor
>> explicit over implicit a little more strongly.
>
> They introduce unnecessary ambiguity: the indentation-as-structure and
> braces-as-structure can then disagree.
>
> The ambiguity is resolved by having exactly one of indentation or braces
> determining structure: Python uses indentation. In which case, braces
> are pointless for indicating block structure.

That's why it wouldn't be Python. It would have to use the braces and
not the indentation.

ChrisA
PS. I mistakenly sent this to a Gilbert & Sullivan group first. Oddly
enough, opera-goers are not used to discussing the relative merits of
braces vs indentation in code.



More information about the Python-list mailing list