This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author mark_t_russell
Recipients
Date 2004-07-31.21:49:13
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=1017234

I've updated the patch again.  See my previous
comment here for the procedure to apply the patch.

Main changes:

     - Added decorator support to Lib/compiler.
       test_decorators.py now passes when compiled
       with Lib/compiler.  The regression tests
       also pass when built with
       Tools/compiler/regrtest.py, apart from
       test_dis.py which I assume is due to
       trivial differences in the bytecode output.
       
     - Added a description of decorators to the
       reference manual.  Changed the docs for
       staticmethod and classmethod in the library
       manual to use decorator syntax (with a pointer
       to the decorator description in the
       reference manual).

     - Added more tests to test_decorator.py,
       including some possibly useful example
       decorators (e.g. memoize)

Other changes (not directly related to decorators):
           
     - I regenerated Lib/compiler/ast.py using
       Tools/compiler/astgen.py.  I'm not sure
       whether astgen.py is still in use -- I had
       to tweak it a bit to make the output match
       ast.py.  I changed astgen.py to emit the
       classes in alphabetical rather than dict
       scan order to make it easier to diff the
       output against ast.py

     - test_pyclbr.py had a broken definition of
       assertEquals - it always returned True if
       called with two arguments.  I renamed this
       to assertEqualsOrIgnored and fixed the bug.
       The working test revealed a test failure in
       pyclbr.py:

     - Changed pyclbr to use the full (dotted)
       module name for pyclbr.Class.module attribute
       
Issues:

     - test_pyclbr.py currently fails because its
       is_method() method fails to spot staticmethod-
       and classmethod- wrapped methods.  See the
       comment on the new test test_decorators().
       I'll have another look at this next week.
       Note that this is a problem with the test,
       not the pyclbr.py module.  For now
       test_decorator could just be deleted.
History
Date User Action Args
2007-08-23 15:38:17adminlinkissue979728 messages
2007-08-23 15:38:17admincreate