[Python-Dev] Re: PEP 318: Decorators last before colon (original) (raw)

Mark Russell marktrussell at btopenworld.com
Mon Apr 5 16:08:19 EDT 2004


On Mon, 2004-04-05 at 19:59, Fred L. Drake, Jr. wrote:

Another possibility might be to require the construct start without the whitespace:

"[as" WHITESPACE ... "]" That avoids the buffering issue and matches what most programmer are more likely to write anyway.

I think that's probably too arbitrary a restriction. Another thought: presumably the parser could handle this syntax if "as" were a keyword. Is that true, and if so, is making "as" a keyword out of the question? The change could presumably be enabled by a "from future" directive to avoid breaking existing code.

Mark



More information about the Python-Dev mailing list