mirror of
https://github.com/jerryscript-project/jerryscript.git
synced 2025-12-15 16:29:21 +00:00
Remove dead code from ecma_date_parse_year() (#3387)
Code cleanup after #3314. Reverting already parsed '-' sign after parse fail is unnecessary, because in this case the whole date parse is failed. Additionally this dead code was incorrect too, because it didn't modify the original pointer to the string, but a local variable. JerryScript-DCO-1.0-Signed-off-by: Csaba Osztrogonác oszi@inf.u-szeged.hu
This commit is contained in:
parent
0bc42a3fd5
commit
51efba40b4
@ -133,10 +133,6 @@ ecma_date_parse_year (const lit_utf8_byte_t **str_p, /**< pointer to the cesu8 s
|
||||
return parsed_year;
|
||||
}
|
||||
|
||||
if (is_year_sign_negative)
|
||||
{
|
||||
str_p--; /* Parse failed, revert already parsed '-' sign. */
|
||||
}
|
||||
return ecma_number_make_nan ();
|
||||
} /* ecma_date_parse_year */
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user