Showing content from http://mail.python.org/pipermail/python-dev/attachments/20110303/cdc7c49a/attachment.html below:
<div class="gmail_quote"><br><div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>
><br>
> 1) define PyModuleDef<br>
> 2) change PyString_AS_STRING calls to _PyUnicode_AsString<br>
<br>
</div>Aside: Please don't use private APIs in Python extensions. Esp.<br>
the above Unicode API is likely going to be phased out.<br>
<br>
You're better off, using PyUnicode_AsUTF8String() instead and<br>
then leaving the PyString_AS_STRING() macro in place.<br></blockquote></div><div><br>In
the standart Python 3.2 source tree, Modules/_lsprof.c uses that
internal function _PyUnicode_AsString. Internal means internal to the
whole distribution here I think?. But IMHO, this should not be the case,
C API modules in the standart dist. should not use internal functions
of other areas. Like in the example: cProfile code has nothing to do
with the Unicode internals. New developers like me, are in need a
consistent examples of usage of Python C API, especially on Python 3.2.<br>
<br>Thanks,<br></div>
</div>
</div><br><br clear="all"><br>-- <br>Sumer Cip
RetroSearch is an open source project built by @garambo
| Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4