/* * @file a.cpp * @author Krzysztof Czainski <1czajnik@gmail.com> */ // This goes before #include "a.hpp" only in this file "a.cpp" to work around compiler error // "prototype for 'A::A(boost::rv&)' does not match any in class 'A'" // which is caused by the fact, that rv is attributed `may_alias` #include #if defined(__GNUC__) && defined(BOOST_NO_RVALUE_REFERENCES) #define GCC_WORKAROUND_MAY_ALIAS_RV_UGLY_HACK_VIOLATING_ODR #endif #include "a.hpp" struct A::Impl {}; A::A() : impl_( new Impl ) {} A::~A() {} A::A( BOOST_RV_REF(A) a ) : impl_( a.impl_.release() ) {}