DateParser is a GenericLexer, which is not particularly UTF-8 aware.
Other engines do not accept ASCII input, so let's just reject non-ASCII
strings outright.
While we are here, let's avoid the std ctype header. It is explicitly
undefined behavior to provide code points to isspace, isalpha, etc. that
do not fit in an unsigned char. Although this isn't reachable any longer
let's just nip it in the bud and use our safe AK character types.
Just to demonstrate, the following returns different values for me on
different systems and with different compilers:
isdigit(0xff01)
isalpha(0xff01)
isspace(0xff01)
|
||
|---|---|---|
| .. | ||
| AST | ||
| Bytecode | ||
| Runtime | ||
| CMakeLists.txt | ||
| test-bytecode-cache.cpp | ||
| test-js-ast.py | ||
| test-js-bytecode.py | ||
| test-js.cpp | ||
| test-primitive-string.cpp | ||
| test-value-js.cpp | ||