You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Merge pull request #90794 from vnen/gdscript-no-unused-constant-warning-with-underscore
GDScript: Suppress unused constant warning with underscore
This commit is contained in:
@@ -1997,7 +1997,7 @@ void GDScriptAnalyzer::resolve_constant(GDScriptParser::ConstantNode *p_constant
|
||||
|
||||
#ifdef DEBUG_ENABLED
|
||||
if (p_is_local) {
|
||||
if (p_constant->usages == 0) {
|
||||
if (p_constant->usages == 0 && !String(p_constant->identifier->name).begins_with("_")) {
|
||||
parser->push_warning(p_constant, GDScriptWarning::UNUSED_LOCAL_CONSTANT, p_constant->identifier->name);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user