Opened 7 years ago

Closed 7 years ago

#11758 closed Bugs (fixed)

BOOST_MOVABLE_BUT_NOT_COPYABLE doesn't reset private access with rvalue ref version

Reported by: lukester_null@… Owned by: Ion Gaztañaga
Milestone: To Be Determined Component: move
Version: Boost 1.59.0 Severity: Problem
Keywords: Cc:

Description

Hi

As subject, BOOST_NO_CXX11_RVALUE_REFERENCES version of BOOST_MOVABLE_BUT_NOT_COPYABLE from core.hpp:

   #define BOOST_MOVABLE_BUT_NOT_COPYABLE(TYPE)\
      BOOST_MOVE_IMPL_NO_COPY_CTOR_OR_ASSIGN(TYPE)\
      public:\
      operator ::boost::rv<TYPE>&() \
      {  return *BOOST_MOVE_TO_RV_CAST(::boost::rv<TYPE>*, this);  }\
      operator const ::boost::rv<TYPE>&() const \
      {  return *BOOST_MOVE_TO_RV_CAST(const ::boost::rv<TYPE>*, this);  }\
      private:\
   //

rvalue ref version:

   #define BOOST_MOVABLE_BUT_NOT_COPYABLE(TYPE)\
      BOOST_MOVE_IMPL_NO_COPY_CTOR_OR_ASSIGN(TYPE)\
      public:\
      typedef int boost_move_emulation_t;\
   //

Caused some head-scratching...

Regards

Luke Elliott.

Change History (1)

comment:1 by Ion Gaztañaga, 7 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.