Merge pull request #35900 from yamgent/unreachable

Fix false positive "Unreachable code" warning for loops
This commit is contained in:
Rémi Verschelde 2020-05-21 10:59:59 +02:00 committed by GitHub
commit af366c7adf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 2 deletions

View File

@ -3167,7 +3167,6 @@ void GDScriptParser::_parse_block(BlockNode *p_block, bool p_static) {
if (error_set) {
return;
}
p_block->has_return = cf_while->body->has_return;
p_block->statements.push_back(cf_while);
} break;
case GDScriptTokenizer::TK_CF_FOR: {
@ -3308,7 +3307,6 @@ void GDScriptParser::_parse_block(BlockNode *p_block, bool p_static) {
if (error_set) {
return;
}
p_block->has_return = cf_for->body->has_return;
p_block->statements.push_back(cf_for);
} break;
case GDScriptTokenizer::TK_CF_CONTINUE: {