Changeset 165:20f165f22d0f in rrlib_util


Ignore:
Timestamp:
13.04.2018 17:31:10 (19 months ago)
Author:
Max Reichardt <mreichardt@…>
Branch:
17.03
Parents:
163:d8b807f8ee7e (diff), 164:7b47551c117c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Phase:
public
Message:

Merge with 14.08

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tEnumBasedFlags.h

    r163 r165  
    125125  bool Get(TFlag flag) const 
    126126  { 
    127     return this->wrapped & (1 << static_cast<TStorage>(flag)); 
     127    return this->wrapped & (static_cast<TStorage>(1) << static_cast<TStorage>(flag)); 
    128128  } 
    129129 
     
    146146    if (value) 
    147147    { 
    148       this->wrapped |= (1 << static_cast<TStorage>(flag)); 
     148      this->wrapped |= (static_cast<TStorage>(1) << static_cast<TStorage>(flag)); 
    149149    } 
    150150    else 
    151151    { 
    152       this->wrapped &= (~(1 << static_cast<TStorage>(flag))); 
     152      this->wrapped &= (~(static_cast<TStorage>(1) << static_cast<TStorage>(flag))); 
    153153    } 
    154154    return *this; 
  • tEnumBasedFlags.h

    r164 r165  
    9999//---------------------------------------------------------------------- 
    100100public: 
     101 
     102  typedef TFlag tFlag; 
     103  typedef TStorage tStorage; 
    101104 
    102105  constexpr tEnumBasedFlags(TFlag flag) : 
Note: See TracChangeset for help on using the changeset viewer.