quickjs/tests
Charlie Gordon 5a7e578482
Improve parsing error messages (#405)
- output more informative error messages in `js_parse_expect`.

The previous code was bogus:
```
    return js_parse_error(s, "expecting '%c'", tok);
```
this was causing a bug on `eval("do;")` where `tok` is `TOK_WHILE` (-70, 0xBA)
creating an invalid UTF-8 encoding (lone trailing byte).
This would ultimately have caused a failure in `JS_ThrowError2` if `JS_NewString`
failed when converting the error message to a string if the conversion detected the invalid
UTF-8 encoding and throwed an error (it currently does not, but should).

- test for `JS_NewString` failure in `JS_ThrowError2`
- test for `JS_FreeCString` failure in run-test262.c
- add more test cases
2024-05-14 20:36:10 +02:00
..
bjson.c Replace JSValueConst with JSValue (#195) 2023-12-10 15:15:42 +01:00
function_source.js Retain function source code in serialized bytecode (#218) 2023-12-16 01:01:26 +01:00
microbench.js Add utility functions for string to integer conversions (#366) 2024-04-19 11:35:44 +02:00
test262.patch 2020-01-05 release 2020-09-06 18:53:08 +02:00
test_bigint.js Remove trailing whitespace (#46) 2023-11-12 10:01:40 +01:00
test_bjson.js Improve Date.parse (#289) 2024-03-10 10:34:26 +01:00
test_builtin.js Fix encoding bug in js_dtoa_radix (#399) 2024-05-07 19:35:34 +02:00
test_closure.js Remove trailing whitespace (#46) 2023-11-12 10:01:40 +01:00
test_conv.c Add utility functions for string to integer conversions (#366) 2024-04-19 11:35:44 +02:00
test_language.js Improve parsing error messages (#405) 2024-05-14 20:36:10 +02:00
test_loop.js Remove trailing whitespace (#46) 2023-11-12 10:01:40 +01:00
test_queue_microtask.js Add queueMicrotask 2023-11-21 23:43:17 +01:00
test_std.js Implement setInterval() (#338) 2024-03-30 09:36:38 +01:00
test_worker.js Refactor build system to use CMake only 2023-11-17 13:10:18 +01:00
test_worker_module.js Remove trailing whitespace (#46) 2023-11-12 10:01:40 +01:00