Esempio n. 1
0
 // GID - GID
 friend gid_type operator- (gid_type const& lhs, gid_type const& rhs)
 {
     boost::uint64_t lsb = lhs.id_lsb_ - rhs.id_lsb_;
     boost::uint64_t msb = lhs.id_msb_ - rhs.id_msb_;
     if (lsb > lhs.id_lsb_)
         --msb;
     return gid_type(msb, lsb);
 }
Esempio n. 2
0
 // GID + GID
 friend gid_type operator+ (gid_type const& lhs, gid_type const& rhs)
 {
     boost::uint64_t lsb = lhs.id_lsb_ + rhs.id_lsb_;
     boost::uint64_t msb = lhs.id_msb_ + rhs.id_msb_;
     if (lsb < lhs.id_lsb_ || lsb < rhs.id_lsb_)
         ++msb;
     return gid_type(msb, lsb);
 }
Esempio n. 3
0
 friend gid_type operator& (gid_type const& lhs, std::uint64_t rhs)
 {
     return gid_type(lhs.id_msb_, lhs.id_lsb_ & rhs);
 }
Esempio n. 4
0
 // GID - std::uint64_t
 friend gid_type operator- (gid_type const& lhs, std::uint64_t rhs)
 { return lhs - gid_type(0, rhs); }
Esempio n. 5
0
File: name.hpp Progetto: adk9/hpx
 // GID + boost::uint64_t
 friend gid_type operator+ (gid_type const& lhs, boost::uint64_t rhs)
 { return lhs + gid_type(0, rhs); }