You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +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:
@@ -368,7 +368,7 @@ NodePath::NodePath(const String &p_path) {
|
||||
for (int i = from; i <= path.length(); i++) {
|
||||
if (path[i] == ':' || path[i] == 0) {
|
||||
String str = path.substr(from, i - from);
|
||||
if (str == "") {
|
||||
if (str.is_empty()) {
|
||||
if (path[i] == 0) {
|
||||
continue; // Allow end-of-path :
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user