|
Boost : |
From: ¿ÂÃÍ (k.meng_at_[hidden])
Date: 2002-11-11 21:23:56
Hi:
I have a question, if my base class has a clone pure virtual function,what can I do to write
the wrap class?
struct Base
{
virtual int f() = 0;
virtual Base* clone() = 0;
};
struct BaseWrap : Base
{
BaseWrap(PyObject* self_)
: self(self_) {}
int f() { return call_method<int>(self, "f"); }
Base* clone(){ return call_method<Base*>(self, "clone");}
PyObject* self;
};
If I write it like this,it report compile error.
kemeng
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk