0
0
This commit is contained in:
Pcornat 2023-12-07 19:43:12 +01:00
parent 425f2dd052
commit 8a1eb79841
Signed by: Pcornat
GPG Key ID: E0326CC678A00BDD

View File

@ -117,7 +117,23 @@ namespace pb1 {
word.clear();
}
break;
case 't':
case 't': {
if (nb_characters_remaining < digitLetters[2].size()) {
line_with_numbers.append(toSearch.substr(i));
continue;
}
word.append(toSearch.substr(i, digitLetters[2].size()));
if (!numbersSet.contains(word)) {
const auto pos = word.find_first_of(digits);
if (pos != std::string::npos) {
line_with_numbers.push_back(word[pos]);
}
} else {
line_with_numbers.push_back(numbersSet.at(word));
i += 2;
}
word.clear();
}
break;
case 'f':
break;