Version bumb, some reformatting

This commit is contained in:
Steffen Schuemann 2018-09-23 14:54:53 +02:00
parent 63f2c2af1a
commit 993d03be4c

View File

@ -101,7 +101,7 @@
#define LWG_2937_BEHAVIOUR
// ghc::filesystem version in decimal (major * 10000 + minor * 100 + patch)
#define GHC_FILESYSTEM_VERSION 10001L
#define GHC_FILESYSTEM_VERSION 10002L
namespace ghc {
namespace filesystem {
@ -1059,9 +1059,10 @@ static const uint32_t utf8_state_info[] = {
0x3333333au, 0x33433333u, 0x9995666bu, 0x99999999u,
0x88888880u, 0x22818108u, 0x88888881u, 0x88888882u,
0x88888884u, 0x88888887u, 0x88888886u, 0x82218108u,
0x82281108u, 0x88888888u, 0x88888883u, 0x88888885u
0x82281108u, 0x88888888u, 0x88888883u, 0x88888885u,
};
static inline unsigned consumeUtf8Fragment(const unsigned state, const uint8_t fragment, uint32_t& codepoint) {
static inline unsigned consumeUtf8Fragment(const unsigned state, const uint8_t fragment, uint32_t& codepoint)
{
uint8_t category = fragment < 128 ? 0 : (utf8_state_info[(fragment >> 3) & 0xf] >> ((fragment & 7) << 2)) & 0xf;
codepoint = (state ? (codepoint << 6) | (fragment & 0x3f) : (0xff >> category) & fragment);
return state == S_RJCT ? S_RJCT : (utf8_state_info[category + 16] >> (state << 2)) & 0xf;