| author | Gareth Stockwell <gareth.stockwell@accenture.com> |
| Fri, 24 Sep 2010 12:07:03 +0100 | |
| branch | graphics-phase-3 |
| changeset 115 | 7fc47a6656f3 |
| parent 1 | 2fb8b9db1c86 |
| permissions | -rw-r--r-- |
#include "Python.h" static PyObject * ex_foo(PyObject *self, PyObject *args) { printf("Hello, world\n"); Py_INCREF(Py_None); return Py_None; } static PyMethodDef example_methods[] = { {"foo", ex_foo, METH_VARARGS, "foo() doc string"}, {NULL, NULL} }; PyMODINIT_FUNC initexample(void) { Py_InitModule("example", example_methods); }