Implement UnicodeEscape abstract method (#3959)
Also refactored ecma_builtin_json_quote to use the method above JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
This commit is contained in:
@@ -46,3 +46,8 @@ try {
|
||||
} catch (e) {
|
||||
assert(e instanceof TypeError);
|
||||
}
|
||||
|
||||
// Checking quoting strings
|
||||
assert(JSON.stringify("ab𬄕c") === '"ab𬄕\\u001fc"');
|
||||
assert(JSON.stringify("ab\uDC01cd") === '"ab\\udc01c\\u001fd"');
|
||||
assert(JSON.stringify("ab\uDC01cd\uD8331e") === '"ab\\udc01c\\u001fd\\ud8331e"');
|
||||
|
||||
Reference in New Issue
Block a user