In Glom, to execute arbitrary Python code, I use PyRun_String() to parse the Python code, PyDict_GetItemString() and PyObject_Call() to get a callable object for that code, and then PyObject_CallObject() to actually execute the code and get a return value. This was the result of experimentation and code archeology: http://git.gnome.org/browse/glom/tree/glom/python_embed/glom_python.cc?h=glom-1-12#n269
Is there anything in boost::python that wraps this, so I can make the code nicer? -- murr...@murrayc.com www.murrayc.com www.openismus.com _______________________________________________ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/mailman/listinfo/cplusplus-sig