Core: Add [[nodiscard]] to string-like classes

This commit is contained in:
Thaddeus Crews 2024-06-23 12:28:04 -05:00
parent 6a6a1168a5
commit 579feb387c
No known key found for this signature in database
GPG key ID: 8C6E5FEB5FC03CCC
12 changed files with 22 additions and 21 deletions

View file

@ -2854,7 +2854,8 @@ String GDScriptLanguage::get_global_class_name(const String &p_path, String *r_b
if (subclass->extends_used) {
if (!subclass->extends_path.is_empty()) {
if (subclass->extends.is_empty()) {
get_global_class_name(subclass->extends_path, r_base_type);
// We only care about the referenced class_name.
_ALLOW_DISCARD_ get_global_class_name(subclass->extends_path, r_base_type);
subclass = nullptr;
break;
} else {