Changeset 3587


Ignore:
Timestamp:
Jan 19, 2017, 1:44:49 PM (5 years ago)
Author:
Peter
Message:

move constructor for vector; refs #878 and #474

Location:
trunk/yat/utility
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/utility/Vector.cc

    r3210 r3587  
    6363  {
    6464  }
     65
     66
     67#ifdef YAT_HAVE_RVALUE
     68  Vector::Vector(Vector&& other)
     69    : VectorMutable(other.vec_)
     70  {
     71    other.vec_ = NULL;
     72    other.const_vec_ = NULL;
     73  }
     74#endif
    6575
    6676
  • trunk/yat/utility/Vector.h

    r3101 r3587  
    2929*/
    3030
     31#include "config_public.h"
     32
    3133#include "VectorMutable.h"
    3234#include "Exception.h"
     
    7880    */
    7981    Vector(const Vector& other);
     82
     83#ifdef YAT_HAVE_RVALUE
     84    /**
     85       \brief The move constructor.
     86    */
     87    Vector(Vector&& other);
     88#endif
    8089
    8190    /**
Note: See TracChangeset for help on using the changeset viewer.