diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2022-11-23 17:21:41 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2022-11-23 17:21:41 +0100 |
commit | 49bb53093d5567deefa55eb1bef9951aed9b2f95 (patch) | |
tree | bc1ba4e0b594fca3eb32143f643741dadd9b6cbd | |
parent | dc671bdc0facc7632ba475ffad907a0060bf021b (diff) | |
parent | 2918689ff1d0c9477aa55f6979e426ce74d01db7 (diff) |
Merge pull request #68985 from adamscott/fix-godot#68977-constant-parameters
Fix parameters that are considered as constants
-rw-r--r-- | modules/gdscript/gdscript_analyzer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_analyzer.cpp b/modules/gdscript/gdscript_analyzer.cpp index 584bb74e4f..9b0dc9577b 100644 --- a/modules/gdscript/gdscript_analyzer.cpp +++ b/modules/gdscript/gdscript_analyzer.cpp @@ -1725,7 +1725,6 @@ void GDScriptAnalyzer::resolve_parameter(GDScriptParser::ParameterNode *p_parame } else { result.type_source = GDScriptParser::DataType::INFERRED; } - result.is_constant = false; } if (p_parameter->datatype_specifier != nullptr) { @@ -1745,6 +1744,7 @@ void GDScriptAnalyzer::resolve_parameter(GDScriptParser::ParameterNode *p_parame push_error(vformat(R"(Could not infer the type of the variable "%s" because the initial value is "null".)", p_parameter->identifier->name), p_parameter->default_value); } + result.is_constant = false; p_parameter->set_datatype(result); } |