[C++-SIG] Problem with last version of py_cpp
Xavier JUVIGNY
Xavier.Juvigny at onera.fr
Wed Nov 8 14:28:38 CET 2000
Hi,
I try to use the last version of py_cpp on a Unix station with gcc
2.95.1
I had a problem with a method with three arguments.
The folowing example :
#include <py_cpp/class_wrapper.h>
class A
{
public:
A()
{}
void f(int,int,int,float,float,float)
{
}
};
void initMesh()
{
try
{
// Create the object representing this extension module
py::Module PyA("A");
// Create the Python type object for our extension class.
py::ClassWrapper<A> A_class(PyA, "PyA");
//
A_class.def(&A::f, "f");
}
catch(...)
{
py::handle_exception();
}
}
give me the unexcepted error :
/data/Wksp/juvigny/Decoupeur.d/py_cpp/functions.h: In function `class
py::Function * py::new_wrapped_function<void (A::*)(int, int, int,
float, float, float)>(void (A::*)(int, int, int, float, float, float))':
/data/Wksp/juvigny/Decoupeur.d/py_cpp/extclass.h:371: instantiated
from `py::ExtensionClass<A,py::HeldInstance<A> >::def<void (A::*)(int,
int, int, float, float, float)>(void (A::*)(int, int, int, float, float,
float), const char *)'
/data/Wksp/juvigny/Decoupeur.d/py_cpp/class_wrapper.h:35: instantiated
from `py::ClassWrapper<A,py::HeldInstance<A> >::def<void (A::*)(int,
int, int, float, float, float)>(void (A::*)(int, int, int, float, float,
float), const char *)'
Py_A.C:22: instantiated from here
/data/Wksp/juvigny/Decoupeur.d/py_cpp/functions.h:127: no matching
function for call to `return_value (void (A::* &)(int, int, int, float,
float, float))'
Has anyone a idea ?
Thanks for help.
Juvigny Xavier
More information about the Cplusplus-sig
mailing list