MCPcopy Create free account
hub / github.com/Redot-Engine/redot-engine / resolve_constant

Method resolve_constant

modules/gdscript/gdscript_analyzer.cpp:2231–2243  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2229}
2230
2231void GDScriptAnalyzer::resolve_constant(GDScriptParser::ConstantNode *p_constant, bool p_is_local) {
2232 static constexpr const char *kind = "constant";
2233 resolve_assignable(p_constant, kind);
2234
2235#ifdef DEBUG_ENABLED
2236 if (p_is_local) {
2237 if (p_constant->usages == 0 && !String(p_constant->identifier->name).begins_with("_")) {
2238 parser->push_warning(p_constant, GDScriptWarning::UNUSED_LOCAL_CONSTANT, p_constant->identifier->name);
2239 }
2240 }
2241 is_shadowing(p_constant->identifier, kind, p_is_local);
2242#endif // DEBUG_ENABLED
2243}
2244
2245void GDScriptAnalyzer::resolve_parameter(GDScriptParser::ParameterNode *p_parameter) {
2246 static constexpr const char *kind = "parameter";

Callers

nothing calls this directly

Calls 3

begins_withMethod · 0.80
StringClass · 0.50
push_warningMethod · 0.45

Tested by

no test coverage detected