[C++-sig] this used to work?

Nikolay Mladenov nickm at sitius.com
Tue Aug 19 23:41:54 CEST 2003


Hi,

This code used to work before (1_29_0), but now(boost-consulting:cvs
from yesterday) it does not:


//////////////////////////////////////////
class OBJ{
public :
    virtual int f()=0;
};

#include <boost/python.hpp>

using namespace boost::python;

BOOST_PYTHON_MODULE(obj)
{
        class_<OBJ, boost::noncopyable>("OBJ", no_init );
}
////////////////////////////////////////////



MSVC 6.5 complains

D:\shared\boost_1_31_0\boost\boost\python\object\value_holder.hpp(54) :
error C2259: 'OBJ' : cannot instantiate abstract class due to following
members:
        s:\temp\inner.cpp(1) : see declaration of 'OBJ'
        d:\projects\boost_1_31_0\boost\boost\python\class.hpp(589) : see
reference to class template instantiation
'boost::python::objects::value_holder<class OBJ>' being compiled
        d:\projects\stlport-4.5.3\stlport\stl\_alloc.h(349) : while
compiling class-template member function 'void __thiscall
boost::python::class_<class OBJ,class boost::noncopyable,struct
boost::python::detail::not_specified,struct boost::p
ython::detail::not_specified>::register_(void) const'
d:\projects\boost_1_31_0\boost\boost\python\object\value_holder.hpp(54)
: warning C4259: 'int __thiscall OBJ::f(void)' : pure virtual function
was not defined
        s:\temp\inner.cpp(5) : see declaration of 'f'
        d:\projects\boost_1_31_0\boost\boost\python\class.hpp(589) : see
reference to class template instantiation
'boost::python::objects::value_holder<class OBJ>' being compiled
        d:\projects\stlport-4.5.3\stlport\stl\_alloc.h(349) : while
compiling class-template member function 'void __thiscall
boost::python::class_<class OBJ,class boost::noncopyable,struct
boost::python::detail::not_specified,struct boost::p
ython::detail::not_specified>::register_(void) const'





More information about the Cplusplus-sig mailing list