diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-05-13 15:42:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-13 15:42:29 +0200 |
commit | e7c9d818766a119089873e4941e4865fb36883ec (patch) | |
tree | a0f50806e5b9e0d122d3f1902bcaf007df1bfcc4 | |
parent | dc649684beac22ab66a49700e0d028468747749e (diff) | |
parent | 3e10392d4845d8f3aa3a271186812377023cc19f (diff) |
Merge pull request #38609 from ThakeeNathees/range-crash-with-non-numeric-const-fix
range() with non-numeric const argument crash fix
-rw-r--r-- | modules/gdscript/gdscript_parser.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp index e12018fd13..b900ba903f 100644 --- a/modules/gdscript/gdscript_parser.cpp +++ b/modules/gdscript/gdscript_parser.cpp @@ -3304,6 +3304,8 @@ void GDScriptParser::_parse_block(BlockNode *p_block, bool p_static) { ConstantNode *c = static_cast<ConstantNode *>(op->arguments[i]); if (c->value.get_type() == Variant::FLOAT || c->value.get_type() == Variant::INT) { constants.push_back(c->value); + } else { + constant = false; } } else { constant = false; |