[Python-3000] Reserve "pragma" keyword in Python 3.0?
Larry Hastings
larry at hastings.org
Sat Mar 22 00:26:23 CET 2008
I think Python needs a dedicated "pragma" syntax; we already have two
pragma syntaxes ("from __future__ import" and "# coding"), and I think a
syntax designed for expressing pragmas would be much clearer than using
existing language features in weird ways to express pragmas. But that's
a debate for another day.
Today's topic is much smaller in scope: can I get support for making
"pragma" a reserved keyword in Python? Guido himself suggested doing
that back in August of 2000 during a previous pragma-y discussion:
http://mail.python.org/pipermail/python-dev/2000-August/008840.html
I'm not proposing that the keyword do anything, just that "pragma" be
reserved for future expansion, and therefore be illegal for use as an
identifier. For now any use of it would be an error.
If there's some chance it would be accepted, I would happily make the patch.
Driving the thin end of the wedge,
/larry/
More information about the Python-3000
mailing list