On Fri, Dec 08, 2006 at 09:48:04AM -0800, Talin wrote: > One other minor brainstorm before I head off to work: I'd like function= =20 > decorators to work with assignment statements as well as 'def' statements. >=20 > Use case: >=20 > class Foo: >=20 > @private > def myfunc(): > pass >=20 > @private > selected =3D True >=20
What would get passed to the decorator in the case of assignment? It
would seem logical for it to be something like:
def private(name, value):
pass
However, function decorators get something like:
def private(func):
pass
Would these be unified, or would something completely different happen?
--
Andrew McNabb
http://www.mcnabbs.org/andrew/
PGP Fingerprint: 8A17 B57C 6879 1863 DE55 8012 AB4D 6098 8826 6868
pgpKWGV2CS5BV.pgp
Description: PGP signature
_______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
