diff --git a/include/Kyoto/Streams/StreamSupport.hpp b/include/Kyoto/Streams/StreamSupport.hpp new file mode 100644 index 00000000..ee85e032 --- /dev/null +++ b/include/Kyoto/Streams/StreamSupport.hpp @@ -0,0 +1,9 @@ +#ifndef _STREAMSUPPORT +#define _STREAMSUPPORT +#include + +static inline uint min_containing_bytes(uint bits) { + return (bits / 8) + ((bits % 8) != 0); +} + +#endif // _STREAMSUPPORT