16999 {
17001 char8_t code1, code2, code3, code4;
17003 code1 = *in++;
17004 if(code1 < 0x80){
17005 *out = code1;
17006 return 1;
17007 }
17009 return npos;
17011 if(in_size_max < 2)
17012 return npos;
17013 code2 = *in++;
17014 if((code2 & 0xC0) != 0x80)
17015 return npos;
17016 *out = (code1 << 6) + code2 - 0x3080;
17017 return 2;
17018 }
17020 if(in_size_max < 3)
17021 return npos;
17022 code2 = *in++;
17023 if((code2 & 0xC0) != 0x80)
17024 return npos;
17025 if(code1 == 0xE0 && code2 < 0xA0)
17026 return npos;
17027 code3 = *in++;
17028 if((code3 & 0xC0) != 0x80)
17029 return npos;
17030 *out = (code1 << 12) + (code2 << 6) + code3 - 0xE2080;
17031 return 3;
17032 }
17034 if(in_size_max < 4)
17035 return npos;
17036 code2 = *in++;
17037 if((code2 & 0xC0) != 0x80)
17038 return npos;
17039 if(code1 == 0xF0 && code2 < 0x90)
17040 return npos;
17041 if(code1 == 0xF4 && code2 >= 0x90)
17042 return npos;
17043 code3 = *in++;
17044 if((code3 & 0xC0) != 0x80)
17045 return npos;
17046 code4 = *in++;
17047 if((code4 & 0xC0) != 0x80)
17048 return npos;
17049 *out = (code1 << 18) + (code2 << 12) + (code3 << 6) + code4 - 0x3C82080;
17050 return 4;
17051 }
17052 else
17054 }
#define pop_msvc_warning()
#define push_and_disable_msvc_warning(...)