diff options
author | Georg Brandl <georg@python.org> | 2012-07-01 07:43:20 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2012-07-01 07:43:20 (GMT) |
commit | 3aa0c9dcf3af9c7a17cadeb79de960ba025a0c29 (patch) | |
tree | ccb3f4b9badda28304fc74ee3488a8c9e2117bcb /Doc | |
parent | 4cf1cc71a6c8a83e5bac7660ae900971594e1005 (diff) | |
download | cpython-3aa0c9dcf3af9c7a17cadeb79de960ba025a0c29.zip cpython-3aa0c9dcf3af9c7a17cadeb79de960ba025a0c29.tar.gz cpython-3aa0c9dcf3af9c7a17cadeb79de960ba025a0c29.tar.bz2 |
Fix inconsistent function name in embedding howto.
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/extending/embedding.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/extending/embedding.rst b/Doc/extending/embedding.rst index 3143c99..d004d24 100644 --- a/Doc/extending/embedding.rst +++ b/Doc/extending/embedding.rst @@ -155,13 +155,13 @@ for data conversion between Python and C, and for error reporting. The interesting part with respect to embedding Python starts with :: Py_Initialize(); - pName = PyString_FromString(argv[1]); + pName = PyUnicode_FromString(argv[1]); /* Error checking of pName left out */ pModule = PyImport_Import(pName); After initializing the interpreter, the script is loaded using :c:func:`PyImport_Import`. This routine needs a Python string as its argument, -which is constructed using the :c:func:`PyString_FromString` data conversion +which is constructed using the :c:func:`PyUnicode_FromString` data conversion routine. :: pFunc = PyObject_GetAttrString(pModule, argv[2]); |