Message183210
here's an updated patch incorporating the feedback from Ezio and Eric:
- moved docstrings put in some __special__ method names
- made the description of 'tag' consistent: 'tag' means the elements name (as opposed to 'tag' being a synonym for "element"!)
- docstring args now *stared* as opposed to 'quoted'
I also gave a shot at copying the existing docstrings into their respective C counterparts. But it *seems* like you can't do so
that easily for a C extension. Maybe I missed something though:
>>> from _elementtree import Element as cElement
>>> cElement.__doc__ = 'foobarbaz'
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: can't set attributes of built-in/extension type 'xml.etree.ElementTree.Element'
I see one example in Modules/_json.c where the docstrings were sorta copied and pasted over, so perhaps it's an ok thing to do. |
|
Date |
User |
Action |
Args |
2013-02-28 10:19:56 | dlam | set | recipients:
+ dlam, ezio.melotti, eli.bendersky, docs@python, tshepang, serhiy.storchaka |
2013-02-28 10:19:55 | dlam | set | messageid: <1362046795.22.0.933095701968.issue16954@psf.upfronthosting.co.za> |
2013-02-28 10:19:55 | dlam | link | issue16954 messages |
2013-02-28 10:19:54 | dlam | create | |
|