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

Method resolve_match_branch

modules/gdscript/gdscript_analyzer.cpp:2422–2440  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2420}
2421
2422void GDScriptAnalyzer::resolve_match_branch(GDScriptParser::MatchBranchNode *p_match_branch, GDScriptParser::ExpressionNode *p_match_test) {
2423 // Apply annotations.
2424 for (GDScriptParser::AnnotationNode *&E : p_match_branch->annotations) {
2425 resolve_annotation(E);
2426 E->apply(parser, p_match_branch, nullptr); /// @todo Provide `p_class`.
2427 }
2428
2429 for (int i = 0; i < p_match_branch->patterns.size(); i++) {
2430 resolve_match_pattern(p_match_branch->patterns[i], p_match_test);
2431 }
2432
2433 if (p_match_branch->guard_body) {
2434 resolve_suite(p_match_branch->guard_body);
2435 }
2436
2437 resolve_suite(p_match_branch->block);
2438
2439 decide_suite_type(p_match_branch, p_match_branch->block);
2440}
2441
2442void GDScriptAnalyzer::resolve_match_pattern(GDScriptParser::PatternNode *p_match_pattern, GDScriptParser::ExpressionNode *p_match_test) {
2443 if (p_match_pattern == nullptr) {

Callers

nothing calls this directly

Calls 2

sizeMethod · 0.65
applyMethod · 0.45

Tested by

no test coverage detected