mirror of
https://github.com/jerryscript-project/jerryscript.git
synced 2025-12-15 16:29:21 +00:00
Fix of 'case' / 'default' statements skip during parse of SwitchStatement.
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
This commit is contained in:
parent
0b1b102cfa
commit
2de49cdba7
@ -2038,13 +2038,15 @@ parse_with_statement (void)
|
||||
static void
|
||||
skip_case_clause_body (void)
|
||||
{
|
||||
while (!is_keyword (KW_CASE) && !is_keyword (KW_DEFAULT) && !token_is (TOK_CLOSE_BRACE))
|
||||
while (!is_keyword (KW_CASE)
|
||||
&& !is_keyword (KW_DEFAULT)
|
||||
&& !token_is (TOK_CLOSE_BRACE))
|
||||
{
|
||||
skip_newlines ();
|
||||
if (token_is (TOK_OPEN_BRACE))
|
||||
{
|
||||
skip_braces ();
|
||||
}
|
||||
skip_newlines ();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user