Make constexpr BEInt<Type, 2>::operator Type() C++11-compatible
Multiple return values not permitted until C++14
This commit is contained in:
parent
c2fc2aa44c
commit
e208f80449
|
@ -113,9 +113,10 @@ struct BEInt<Type, 2>
|
||||||
#else /* __BYTE_ORDER == __BIG_ENDIAN */
|
#else /* __BYTE_ORDER == __BIG_ENDIAN */
|
||||||
return ((packed_uint16_t *) this)->v;
|
return ((packed_uint16_t *) this)->v;
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#else
|
||||||
return (v[0] << 8)
|
return (v[0] << 8)
|
||||||
+ (v[1] );
|
+ (v[1] );
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
private: uint8_t v[2];
|
private: uint8_t v[2];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue