[Complex Test Layouts] Change String to use UTF-32 encoding on all platforms.

This commit is contained in:
bruvzg 2020-07-27 13:43:20 +03:00
parent 0864f12f0d
commit 80b8eff6aa
No known key found for this signature in database
GPG key ID: FCED35F1CECE0D3A
94 changed files with 4889 additions and 1686 deletions

View file

@ -36,7 +36,7 @@
VARIANT_ENUM_CAST(XMLParser::NodeType);
static bool _equalsn(const CharType *str1, const CharType *str2, int len) {
static bool _equalsn(const char32_t *str1, const char32_t *str2, int len) {
int i;
for (i = 0; i < len && str1[i] && str2[i]; ++i) {
if (str1[i] != str2[i]) {
@ -64,7 +64,7 @@ String XMLParser::_replace_special_characters(const String &origstr) {
int specialChar = -1;
for (int i = 0; i < (int)special_characters.size(); ++i) {
const CharType *p = &origstr[pos] + 1;
const char32_t *p = &origstr[pos] + 1;
if (_equalsn(&special_characters[i][1], p, special_characters[i].length() - 1)) {
specialChar = i;