Boost logo

Boost :

Subject: Re: [boost] [context] MinGW support?
From: Oliver Kowalke (oliver.kowalke_at_[hidden])
Date: 2011-07-23 06:49:31

Am 23.07.2011 11:35, schrieb Nathan Ridge:
>> Hello Nate,
>> please use - I don't get compiler
>> errors with this source for 32bit/64bit Linux on x86.
>> The errors above point to some problems with boost.move. Which version
>> did you use? Could you test the lib with the sources from github?
> I tried the github sources, but I am getting the same errors.
> I am using the latest SVN trunk, which contains the Move library.
> Is there some other version of the Move library that I'm supposed to be
> using?
> Thanks,
> Nate
> _______________________________________________
> Unsubscribe& other changes:

It is a bug in the boost.move (trunk version). The new version doesn't allow
to separate the implemantion of copy-ctor and assignment-op from
their declaration.

For instance if you modify the examples of boost.move like movable.hpp to:

class movable
int value_;

movable() : value_(1){}

// only declaration
movable(BOOST_RV_REF(movable) m);
movable & operator=(BOOST_RV_REF(movable) m);

bool moved() const //Observer
{ return value_ == 0; }

movable::movable(BOOST_RV_REF(movable) m)
{ value_ = m.value_; m.value_ = 0; }

movable & movable::operator=(BOOST_RV_REF(movable) m)
{ value_ = m.value_; m.value_ = 0; return *this; }

it won't compile for gcc 4.5.2 :

movable.hpp:36:1: error: prototype for
‘movable::movable(boost::rv<movable>&)’ does not match any in class
movable.hpp:28:4: error: candidates are:
movable.hpp:25:4: error: movable::movable()
movable.hpp:21:4: error: movable::movable(movable&)
movable.hpp:39:11: error: prototype for ‘movable&
movable::operator=(boost::rv<movable>&)’ does not match any in class
movable.hpp:30:14: error: candidates are: movable&
movable.hpp:21:4: error: movable& movable::operator=(movable&)

So I believe I've nothing to fix in boost.context - do you agree?


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