[patch] deprecation warnings branch
Robert Collins
robertc at robertcollins.net
Sun Jan 15 20:55:31 GMT 2006
On Wed, 2006-01-11 at 07:04 -0600, John Arbash Meinel wrote:
> If you look at Andrew Bennet's post, they have some code for dynamically
> generating the wrapped function, which can help.
>
> But it might be easiest to do
>
> wrap_func.__doc__ = signature + orig_func.__doc__
>
> Would that be sufficient? If you saw
>
> my_function = wrap(self, *args, **kwargs):
> my_function(self, foo, baz=None)
> stuff about my_function
Hmm, the first line is special though. I'd rather do:
new_doc = orig_func.__doc__ + signature
(appropriately adjusted for indenting of course).
Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060116/fffe3f8e/attachment.pgp
More information about the bazaar
mailing list