Ruben Ayrapetyan
6fe78cc994
Temporary workaround (until parser is refactored) for fixing evaluation of simple 'identifier'-like expressions.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-15 12:52:42 +03:00
Ruben Ayrapetyan
5e329c815c
Fix syntax checking of large object literals.
...
Related issue: #354
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-15 12:41:56 +03:00
Ruben Ayrapetyan
73d082aa55
Fix parse of delete operator.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-15 12:34:51 +03:00
Ruben Ayrapetyan
c120433158
Fix handling of EOF in insert_semicolon.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-15 12:31:47 +03:00
László Langó
cf9d54545f
Style fixes for RegExp engine.
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2015-07-15 11:02:11 +02:00
Zsolt Borbély
1e90f833f7
Implement Function.prototype.bind function
...
JerryScript-DCO-1.0-Signed-off-by: Zsolt Borbély zsborbely.u-szeged@partner.samsung.com
2015-07-15 08:39:35 +02:00
Ruben Ayrapetyan
92bf7859af
Put lexer_init after setjmp in parser_parse_program, as lexer_init could raise an early error.
...
Related issues: #341
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-14 18:42:49 +03:00
Andrey Shitov
1195c197e8
Fix syntax checking for line terminators inside regular expressions.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-14 17:58:24 +03:00
Andrey Shitov
f3ef9afb91
Fix handling of invalid HexIntegerLiterals in lexer.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-14 17:58:24 +03:00
Zoltan Herczeg
69655f4456
Implement toLowerCase and toUpperCase built-in functions.
...
Related issue: #323
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg@inf.u-szeged.hu
2015-07-14 07:01:47 -07:00
SaeHie Park
bc0ca7be5d
Add heap size limit
...
to solve #342
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-07-14 07:44:37 +09:00
SaeHie Park
0927888b44
External build fix
...
Added generic build for none linux platforms, as nuttx has be removed by #330
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-07-14 07:44:37 +09:00
Ruben Ayrapetyan
aa415c670e
Fix initialization of 'this' argument in 'call_n' opcode handler.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-13 19:31:07 +03:00
Ruben Ayrapetyan
c84d31ce9e
Fix sign of number remainder (ecma_op_number_remainder).
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-13 19:21:46 +03:00
Ruben Ayrapetyan
f8770020f7
Update RegExp.prototype.exec so that it returns 'null' instead of 'undefined' in case argument doesn't match corresponding regular expression.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-13 19:05:37 +03:00
Ruben Ayrapetyan
8aa2571699
Fix NaN handling in ecma_op_same_value.
...
Related issue: #130
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-13 18:57:38 +03:00
Ruben Ayrapetyan
710a18d6af
Add 'length' property of String.prototype built-in object.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-13 18:49:45 +03:00
Andrey Shitov
cf2bc459bb
Support unicode whitespaces in string-to-number conversion.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-13 18:33:05 +03:00
Andrey Shitov
b3fa7d9765
Fix function skipping in preparse_scope: properly detect usage of 'function' keyword as property name.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-13 18:01:18 +03:00
Andrey Shitov
7f1a7981b9
Support true, false, null as property names.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-13 18:01:17 +03:00
Andrey Shitov
60bd718fb5
Fix assertion !lit_utf8_iterator_is_eos (iter_p) in lexer.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-13 18:01:17 +03:00
Andrey Shitov
64bbf2752e
Fix printing of the source line with syntax error.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-13 18:01:17 +03:00
SaeHie Park
13cf31413f
Fix EXTERNAL_LIBC_INTERFACE check with USE_COMPILER_DEFAULT_LIBC
...
Related with #331
JerryScript-DCO-1.0-Signed-off-by: SaeHie Park saehie.park@samsung.com
2015-07-12 17:18:52 +09:00
László Langó
9c559216b7
Primitive value of Date.prototype should be NaN
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2015-07-10 13:31:31 +02:00
László Langó
122e5c47c9
Fix assertion in RegExp bytecode realloc.
...
Assertion '!bc_ctx_p->current_p && !bc_ctx_p->block_end_p && !bc_ctx_p->block_start_p' failed in realloc_regexp_bytecode_block
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2015-07-10 10:23:09 +02:00
László Langó
9b24d8fd7a
Implement Date.prototype.toString
...
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2015-07-10 09:43:19 +02:00
László Langó
6e8f7b6e59
Assertion fix in RegExp.
...
Assertion 'mem_pools == NULL' failed in mem_pools_finalize
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
2015-07-10 09:33:23 +02:00
Andrey Shitov
dbf3708255
Fix concatenating of surrogates.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-10 10:23:20 +03:00
Kristof Kosztyo
9fc1958903
Fix the builtin Math.min and Math.max function
...
JerryScript-DCO-1.0-Signed-off-by: Kristof Kosztyo kkosztyo.u-szeged@partner.samsung.com
2015-07-10 09:11:43 +02:00
Szilard Ledan
8d7cdebee0
Implement builtin getters for Date object
...
JerryScript-DCO-1.0-Signed-off-by: Szilard Ledan szledan.u-szeged@partner.samsung.com
2015-07-09 17:04:54 +02:00
Ilya Lopatin
6547cf3b2d
JerryScript-DCO-1.0-Signed-off-by: Ilya Lopatin lopic19@gmail.com
2015-07-09 17:55:50 +03:00
Evgeny Gavrin
9c18648b6c
Fix build for GCC 4.7.
...
JerryScript-DCO-1.0-Signed-off-by: Evgeny Gavrin e.gavrin@samsung.com
2015-07-09 15:38:27 +03:00
Evgeny Gavrin
a26832f3c9
Fix strip handling for cross build configurations.
...
JerryScript-DCO-1.0-Signed-off-by: Evgeny Gavrin e.gavrin@samsung.com
2015-07-09 15:38:27 +03:00
Andrey Shitov
d5fd0b09b1
Properly process Use Strict which contains EscapeSeqence or LineContinuation.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-09 12:43:13 +03:00
Andrey Shitov
17cdc35d6d
Fix detection of Use Strict directive not in the start of Directive Prologue.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-09 12:43:03 +03:00
Andrey Shitov
146ac15b5f
Change locus type from size_t to lit_utf8_iterator_pos_t.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-08 15:53:33 +03:00
Ruben Ayrapetyan
7dd1d01541
Replace character constants with corresponding LIT_CHAR_* definitions in lexer_parse_token (renamed from lexer_next_token_private); replace remaining character constants in lexer with corresponding LIT_CHAR_* definitions.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:53:23 +03:00
Ruben Ayrapetyan
e45f6dc61b
Replace punctuator character constants with corresponding LIT_CHAR_* definitions in lexer_next_token_private.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:53:12 +03:00
Ruben Ayrapetyan
23b847015c
Support unicode whitespace and line terminators in lexer, fix parse of comments.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:53:02 +03:00
Ruben Ayrapetyan
32094622ec
Replace character constants with corresponding LIT_CHAR_* definitions in lexer_parse_regexp (renamed from parse_regexp).
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:52:52 +03:00
Ruben Ayrapetyan
7664bc161b
Replace character constants with corresponding LIT_CHAR_* defines in lexer_parse_string (renamed from parse_string).
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:52:42 +03:00
Ruben Ayrapetyan
1711416e2e
Simplify lexer_parse_number (parse_number) and add unicode support to the function.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:52:31 +03:00
Ruben Ayrapetyan
baf3748d1b
Support unicode in lexer_parse_identifier_name_or_keyword (renamed from parse_name).
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:52:21 +03:00
Ruben Ayrapetyan
6432e4d7cf
Replace convert_string_to_token_transform_escape_seq with lexer_transform_escape_sequences that outputs transformed charset to specified buffer, instead of creating token from the charset.
...
Also the commit introduces lexer_convert_escape_sequence_digits_to_char, adds 'lexer' prefix to convert_single_escape_character and replaces character constants with corresponding LIT_CHAR_* definitions in the function.
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:52:10 +03:00
Ruben Ayrapetyan
b5d30de4d7
Rename decode_keyword to lexer_parse_reserved_word and change it so that it doesn't return TOK_NAME, but empty token instead.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:51:59 +03:00
Andrey Shitov
32318137c3
Switch lexer to utf8 iterators.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-08 15:51:24 +03:00
Andrey Shitov
d248d0944c
Add helper functions for implementing unicode support in lexer.
...
JerryScript-DCO-1.0-Signed-off-by: Andrey Shitov a.shitov@samsung.com
2015-07-08 15:51:02 +03:00
Ruben Ayrapetyan
c21399cd58
Fix ecma_date_parse_date_chars: lit_char_is_unicode_digit -> lit_char_is_decimal_digit.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:20:45 +03:00
Ruben Ayrapetyan
afe58e90ae
Add lit_char_is_octal_digit, lit_char_is_decimal_digit, lit_char_is_hex_digit helpers.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:17:41 +03:00
Ruben Ayrapetyan
393d693e23
Introduce 'USE_COMPILER_DEFAULT_LIBC' for switching from jerry-libc to a libc, provided by compiler.
...
JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
2015-07-08 15:02:40 +03:00