modpython: move CPyRetString to own header.

It was defined twice: in modpython.cpp, and in modpython.i
And there is a fake CPyRetString in modpython.i

Now both places which use real CPyRetString include the file instead.
Fake CPyRetString is still in modpython.i
This commit is contained in:
Alexey Sokolov
2011-03-31 20:10:24 +07:00
parent ba915eb9c4
commit b8043c3aac
3 changed files with 23 additions and 34 deletions

View File

@@ -17,16 +17,7 @@
#include "modpython/swigpyrun.h"
#include "modpython/module.h"
class CPyRetString {
public:
CString& s;
CPyRetString(CString& S) : s(S) {}
static PyObject* wrap(CString& S) {
CPyRetString* x = new CPyRetString(S);
return SWIG_NewInstanceObj(x, SWIG_TypeQuery("CPyRetString*"), SWIG_POINTER_OWN);
}
};
#include "modpython/retstring.h"
class CModPython: public CGlobalModule {