[Python-ideas] Making colons optional?
Riobard Zhan
yaogzhan at gmail.com
Thu Feb 5 19:29:59 CET 2009
On 5-Feb-09, at 1:40 PM, spir wrote:
> Le Thu, 05 Feb 2009 17:53:46 +0100,
> Christian Heimes <lists at cheimes.de> a écrit :
>
> [...]
>> Yes, the colon is extra noise but it's the kind of good noise that
>> makes
>> life more joyful like the noise of rain on a roof. Did you notice
>> that
>> I'm using a colon in my regular postings, too? I've used two colons
>> to
>> separate my text from the examples. Colon separators are natural to
>> me.
>
> So why not support a PEP to introduce compulsory ';' at the end of
> all not-compound statements? All your comments and exemples hold
> both for ordinary statements and block headlines -- or do I miss the
> point?
>
>> The second example makes it even more obvious:
>>
>> if (some() and some_other() or some_more(complex=(True,))
>> and a_final_call(egg=(1,2,3))):
>
> Do(some(), some_other(), some_more(complex=(True,)),
> and_final_call(egg=(1,2,3,zzzzz=False))); # endof
> statement is obvious
This is exactly the point in my mind! :)
If semicolons are optional, so should be colons. If line continuation
really matters, we should use both anyway. Why the irregularity?
More information about the Python-ideas
mailing list