[C++-sig] pyste and C++ namespaces
Nicodemus
nicodemus at esss.com.br
Wed Jan 28 00:12:33 CET 2004
Daniel Holth wrote:
>>This patch allows any keyword arguments to Function() and Class(); if
>>you add a doc="the documentation" argument, it adds the docstring to the
>>wrapper.
>>
>>
>
>The main downside so far is that if you misspell a keyword argument,
>Python will not complain.
>
>
No problem, that's easy to fix.
>Whoops, there should be an additional comma (',') in that docstring
>patch.
>
>def escape_docstring(d):
> # crude escaping; we should also escape " and special characters.
> # we could also expose the function's true name etc. with named
> # replacements, %(foo)s and so on.
> doc = ', "' + "\\n".join(d.splitlines()) + '"'
> return doc
>
>
Got it! Thanks a lot for this patch: I will implement it in CVS soon!
Regards,
Nicodemus.
More information about the Cplusplus-sig
mailing list