PEP 318: Can't we all just get along?
Michael J. Fromberger
Michael.J.Fromberger at Clothing.Dartmouth.EDU
Wed Aug 18 17:42:46 EDT 2004
In article <cfvpf0$p5k$1 at panix3.panix.com>, aahz at pythoncraft.com (Aahz)
wrote:
> In article <20040817181725194-0400 at braeburn.themorgue.org>,
> Kevin Smith <Kevin.Smith at sas.com> wrote:
> >
> >Bear with me, but I'd like to propose one more syntax that is simple,
> >easy for newbies to understand, and nowhere near as powerful as the
> >current PEP's syntax. However, it doesn't add incoherent, arbitrary
> >syntax either.
> >
> >def classmethod foo(x, y, z):
> > pass
>
> You can't do ``grep "def foo"``; therefore, Guido rejected this. (It's
> a tiny bit more complicated than that, but that's the essence.)
I suppose that's understandable; but would it really be so much worse to
have to write:
egrep "def [_a-z0-9]* *foo"
or, even
grep "def" | grep "foo("
I respectfully submit that this, while it makes a certain amount of
sense, is probably not a very good design criterion for new syntactic
features.
-M
--
Michael J. Fromberger | Lecturer, Dept. of Computer Science
http://www.dartmouth.edu/~sting/ | Dartmouth College, Hanover, NH, USA
More information about the Python-list
mailing list