mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 11:01:17 +00:00
Replace String comparisons with "", String() to is_empty()
Also: - Adds two stress tests to test_string.h - Changes to .empty() on std::strings
This commit is contained in:
parent
31ded7e126
commit
49403cbfa0
226 changed files with 1051 additions and 1034 deletions
|
|
@ -75,7 +75,7 @@ void DependencyEditor::_fix_and_find(EditorFileSystemDirectory *efsd, Map<String
|
|||
String path = efsd->get_file_path(i);
|
||||
|
||||
for (KeyValue<String, String> &E : candidates[file]) {
|
||||
if (E.value == String()) {
|
||||
if (E.value.is_empty()) {
|
||||
E.value = path;
|
||||
continue;
|
||||
}
|
||||
|
|
@ -135,7 +135,7 @@ void DependencyEditor::_fix_all() {
|
|||
|
||||
for (KeyValue<String, Map<String, String>> &E : candidates) {
|
||||
for (const KeyValue<String, String> &F : E.value) {
|
||||
if (F.value != String()) {
|
||||
if (!F.value.is_empty()) {
|
||||
remaps[F.key] = F.value;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue