Boost logo

Boost :

From: dietmar_kuehl_at_[hidden]
Date: 2001-09-18 05:26:39

--- In boost_at_y..., Daniel Frey <daniel.frey_at_a...> wrote:
> David Abrahams wrote:
> >
> > > class A : noncopyable {};
> > > class B : public A, noncopyable {};
> >
> > Then you can try to disable the warnings... ;-)
> How about:
> #define BOOST_NONCOPYABLE virtual ::boost::noncopyable

Why would anybody want to do something like this? If a class is
noncopyable, eg. because it derives from 'boost::noncopyable',
all derived classes are automatically noncopyable unless, of course,
someone explicitly implements a copy constructor: For the implicit
copy ctor a copy ctor of all bases and members is necessary! Thus,
the solution to the "problem" is to remove the 'noncopyable' from
the list of bases of 'B'!

<mailto:dietmar_kuehl_at_[hidden]> <>
Phaidros eaSE - Easy Software Engineering: <>

Boost list run by bdawes at, gregod at, cpdaniel at, john at