Zoltan Herczeg
f1dd59e4bd
Property modifiers should not be checked before an equals. ( #3509 )
...
Fixes #3434 .
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2020-01-13 15:14:29 +01:00
Zoltan Herczeg
9a8160176c
Nested destructuring binding patterns should inherit the PARSER_PATTERN_ARGUMENTS flag. ( #3508 )
...
Fixes #3398 .
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2020-01-13 15:13:57 +01:00
Robert Fancsik
d0e8629342
Support nested destructuring patterns in catch header ( #3488 )
...
This patch fixes #3433 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2020-01-13 11:39:07 +01:00
Robert Fancsik
b3b1dfdabd
Tagged template object references should be released only in post_processing ( #3495 )
...
This patch fixes #3483 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2020-01-10 15:25:40 +01:00
Robert Fancsik
dc3de8d8ae
Fix for-of block context creation for empty destructuring pattern ( #3492 )
...
This patch fixes #3421 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2020-01-08 14:55:02 +01:00
Robert Fancsik
003694d259
Throw error for generator function class constructor ( #3489 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2020-01-07 14:52:01 +01:00
Zoltan Herczeg
fa2ddb2466
Create a new file for scanner operations. ( #3475 )
...
Compared to utils, the functions here scan the input (e.g. uses lexer_next_token).
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2020-01-06 11:05:39 +01:00
Zoltan Herczeg
dc15944ebd
Remove lexer_process_char_literal function. ( #3474 )
...
Add a test for using large literals.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2020-01-06 10:13:05 +01:00
Zoltan Herczeg
8cb2be6001
Support parsing async modifiers for functions. ( #3460 )
...
Only parsing is implemented, so the async functions currently behave
like normal function except they return with a resolved Promise object
when the function is terminated correctly.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-20 09:55:41 +01:00
Robert Fancsik
ea5ad2a06f
Fix the parsing/scanning of empty return statement ( #3468 )
...
This patch fixes #3467 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-12-19 19:31:59 +01:00
Robert Fancsik
9596a7e1d6
Implement tagged template literals ( #3456 )
...
Missing features: snapshot support
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-12-19 19:10:45 +01:00
Daniel Balla
52616f7d8c
Early return when the scanner throws an error while parsing an invalid function identifier ( #3464 )
...
Fixes #3454
JerryScript-DCO-1.0-Signed-off-by: Daniel Balla [email protected]
2019-12-19 15:50:09 +01:00
Zoltan Herczeg
d0b4e7dd04
Free three parser status flag bits. ( #3451 )
...
The operations covered by these bits can be done in a different way.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-17 11:43:37 +01:00
Szilagyi Adam
b6f2ff1ba7
Implement binary literal parsing ( #3439 )
...
This patch will allow the user to use binary literals starting with 0b or 0B,
these literals will be evaluated in parsing time resulting an integer
Co-authored-by: Robert Fancsik [email protected]
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi [email protected]
2019-12-17 11:42:29 +01:00
Zoltan Herczeg
3c0beaf87d
Support strict mode detection in the pre-scanner. ( #3450 )
...
Furthermode an error is thrown when 'use strict' is used in a function with non-simple arguments
and function arguments are not moved to lexical environment when unmapped arguments are present.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-17 10:59:03 +01:00
Zoltan Herczeg
b1237dbc5a
Detect keyword type even if the keyword is identifier. ( #3448 )
...
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-16 13:36:26 +01:00
Zoltan Herczeg
40d930d62c
Implement \u{hex} support. ( #3447 )
...
A large rework because surrogate pairs must be combined.
Currently only the 0x10C80..0x10CF2 is accepted as valid identifier character from the non-basic plane.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-16 11:26:02 +01:00
László Langó
c525b1f10a
Fixed segmentation fault in scanner. ( #3444 )
...
The register end index was not correctly calculated when
only holes presented in the arguments list of a function.
Fixes #3419 , fixes #3431
JerryScript-DCO-1.0-Signed-off-by: László Langó [email protected]
2019-12-12 12:17:45 +01:00
Robert Fancsik
9b33fc8cbd
Revise the usage of the global error value/exception flag ( #3426 )
...
This patch also fixes #3422 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-12-10 14:42:10 +01:00
Zoltan Herczeg
531f1e9687
Support let identifier in non-strict mode. ( #3427 )
...
This code adds a lot of checks and complexity to the code.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-10 14:32:08 +01:00
Zoltan Herczeg
b8bc013fc0
Keywords must not contain escape sequences. ( #3429 )
...
The ES5.1 standard is unclear about this rule.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-09 14:37:41 +01:00
Zoltan Herczeg
5ceffd209e
Fix post increase / decrease in the pre-scanner. ( #3430 )
...
Fixes #3397 .
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-06 13:53:34 +01:00
Zoltan Herczeg
1a4972fc3f
Implement yield* operation in generator functions. ( #3407 )
...
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-05 13:50:53 +01:00
Robert Fancsik
1829d2df55
Fix scanner_create_variables for empty destructuring patterns ( #3417 )
...
This patch fixes #3383 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-12-04 15:38:50 +01:00
Zoltan Herczeg
31988877b2
Support destructuring bindings as catch variables. ( #3399 )
...
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-03 12:52:20 +01:00
Zoltan Herczeg
132de45c0b
Remove CBC_EXT_CONTINUE_EXEC opcode. ( #3378 )
...
There is no need for a specific opcode after yield because
the return and throw commands can be redirected to fake byte code sequences.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-12-02 12:37:13 +01:00
Robert Fancsik
0bc42a3fd5
Allow lexical function declaration in labeled statements. ( #3386 )
...
This patch fixes #3381 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-29 16:41:21 +01:00
Zoltan Herczeg
fee3a600af
Support assignment expressions in the pre-scanner. ( #3382 )
...
Fixes #3355 .
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-29 15:47:47 +01:00
Dániel Bátyai
35c0a6e299
Implement RegExp unicode and sticky flags ( #3379 )
...
JerryScript-DCO-1.0-Signed-off-by: Dániel Bátyai [email protected]
2019-11-29 14:08:30 +01:00
Zoltan Herczeg
8956eff2bd
Implement generator support for object initializers and classes. ( #3372 )
...
Large part of the code is also reworked.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-29 12:28:51 +01:00
Zoltan Herczeg
110f75c99d
Implement the core of the generator functions. ( #3368 )
...
Some things are missing:
- yield* support
- generator definition in object literal
- the hidden GeneratorFunction
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-28 11:54:27 +01:00
Robert Fancsik
cbeecdb703
Fix this property reference on assignment patterns ( #3365 )
...
This patch fixes #3348 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-26 15:49:55 +01:00
Robert Fancsik
12211d8aaa
Fix the order of the function arguments for spread operation ( #3369 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-26 15:47:36 +01:00
Robert Fancsik
aeb8431aff
Fix the scanning of default array/object literals. ( #3367 )
...
Scanning should continue with `SCAN_MODE_POST_PRIMARY_EXPRESSION` in all cases.
Fixes #3360 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-26 13:07:28 +01:00
Robert Fancsik
62356796fc
Support get/set as property name in object literal ( #3340 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-22 16:05:38 +01:00
Roland Takacs
996bf76f59
Support ES6 based octal literals ( #3338 )
...
JerryScript-DCO-1.0-Signed-off-by: Roland Takacs [email protected]
2019-11-21 15:13:11 +01:00
Robert Fancsik
2ddf134cef
Add iterator close support for array destructuring ( #3337 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-21 12:55:52 +01:00
Zoltan Herczeg
6b43ef8605
Arrow functions should be parsed as assignment expressions. ( #3336 )
...
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-21 11:32:33 +01:00
Robert Fancsik
7f6f562adb
Throw error for using rest parameter in property setter ( #3335 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-20 12:21:05 +01:00
Robert Fancsik
830011c033
Eliminate the allocation of spread object ( #3333 )
...
ECMA_VALUE_SPREAD_ELEMENT can be used to represent that the next argument needs to be spreaded, therefore no allocation is needed.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-19 18:16:43 +01:00
Zoltan Herczeg
70566a52fb
Improve eval call parsing. ( #3330 )
...
Eval calls are recognised when the eval identifier is encapsulated in brackets.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-19 15:55:53 +01:00
Robert Fancsik
a1189cfb62
Add validation for single statement lexical declarations ( #3326 )
...
This patch fixes #3275 and fixes #3276 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-19 15:44:12 +01:00
Robert Fancsik
22766a855e
Implement spread operator for function call arguments ( #3329 )
...
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-19 14:06:12 +01:00
Zoltan Herczeg
bf630c0c54
Implement binding pattern support for rest argument and for statement. ( #3327 )
...
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-19 14:02:17 +01:00
Zoltan Herczeg
8bdb32cc88
Implement function destructuring argument support. ( #3322 )
...
Furthermore create unmapped arguments objects if a function has a non-simple argument.
A few destructuring pattern issues were fixed as well.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
2019-11-18 14:15:36 +01:00
Robert Fancsik
8cf5f96c15
Introduce parser statement flags ( #3318 )
...
These flags makes the code more readable also makes the process of introducing a new statement type easier.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-15 15:57:42 +01:00
Robert Fancsik
fca0c94002
Fix the initialization of let/const patterns when block context is needed. ( #3320 )
...
Also some code cuplication is removed.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-15 14:38:14 +01:00
Robert Fancsik
8eda9bc1c3
Fix the usage of escaped identifiers in scanner_scope_find_let_declaration ( #3317 )
...
This patch fixes #3313 .
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-14 14:46:01 +01:00
Robert Fancsik
be95aa33b4
Improve delete property with undefined base ( #3312 )
...
This patch finally resolves #2891 also the removes the related bytecode since it has become unnecessary.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-14 13:53:52 +01:00
Robert Fancsik
213544ae47
Implement array/object destructuring ( #3305 )
...
This patch implements the core functionality of destructuring patterns.
Function argument/for in-of pattern are currently unsupported.
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg [email protected]
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
2019-11-14 13:49:49 +01:00