diff --git a/py.h b/py.h index 2cf89807..06365764 100644 --- a/py.h +++ b/py.h @@ -165,6 +165,11 @@ PyObject* to_python(boost::shared_ptr p) // inline implementations // +inline PyObject* to_python(double d) +{ + return PyFloat_FromDouble(d); +} + inline PyObject* to_python(long l) { return PyInt_FromLong(l);