Matt Jones added the comment: Andrew, below is a revision of your comment with a few corrections made by a native english speaker.
******************** Function :c:func:`Py_SetProgramName` should be called before :c:func:`Py_Initialize` to inform the interpreter about paths to Python run-time libraries. Next initialize the Python interpreter with :c:func:`Py_Initialize`, followed by the execution of a hard-coded Python script that prints the date and time. Afterwards, the :c:func:`Py_Finalize` call shuts the interpreter down, followed by the end of the program. In a real program, you may want to get the Python script from another source, perhaps a text-editor routine, a file, or a database. Getting the Python code from a file can better be done by using the :c:func:`PyRun_SimpleFile` function, which saves you the trouble of allocating memory space and loading the file contents. ---------- nosy: +Matt.Jones _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue16370> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com