MCPcopy Create free account
hub / github.com/Aloshi/EmulationStation / decode_utf32_block

Method decode_utf32_block

src/pugiXML/pugixml.cpp:953–976  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

951 }
952
953 static inline typename Traits::value_type decode_utf32_block(const uint32_t* data, size_t size, typename Traits::value_type result)
954 {
955 const uint32_t* end = data + size;
956
957 while (data < end)
958 {
959 uint32_t lead = opt_swap::value ? endian_swap(*data) : *data;
960
961 // U+0000..U+FFFF
962 if (lead < 0x10000)
963 {
964 result = Traits::low(result, lead);
965 data += 1;
966 }
967 // U+10000..U+10FFFF
968 else
969 {
970 result = Traits::high(result, lead);
971 data += 1;
972 }
973 }
974
975 return result;
976 }
977
978 static inline typename Traits::value_type decode_latin1_block(const uint8_t* data, size_t size, typename Traits::value_type result)
979 {

Callers

nothing calls this directly

Calls 1

endian_swapFunction · 0.85

Tested by

no test coverage detected