5 #include <msp/core/mspcore_api.h>
15 M_RDWR = M_READ|M_WRITE,
21 inline Mode operator|(Mode m, Mode n)
22 { return Mode(static_cast<int>(m)|static_cast<int>(n)); }
24 inline Mode operator&(Mode m, Mode n)
25 { return Mode(static_cast<int>(m)&static_cast<int>(n)); }
27 inline Mode operator~(Mode m)
28 { return Mode(~static_cast<int>(m)); }
30 inline void adjust_mode(Mode &m, Mode f, bool b)
31 { m = b ? (m|f) : (m&~f); }
34 class MSPCORE_API invalid_access: public std::logic_error