| 297 | } |
| 298 | |
| 299 | static inline bool Utf8Is2ByteStart(const uint8_t codeunit) { |
| 300 | return (codeunit & 0xE0) == 0xC0; // upper three bits should be 110 |
| 301 | } |
| 302 | |
| 303 | static inline bool Utf8Is3ByteStart(const uint8_t codeunit) { |
| 304 | return (codeunit & 0xF0) == 0xE0; // upper four bits should be 1110 |