As identified in shikijs/shiki#1005, a WebKit bug results in nested negated character classes being treated as if they weren't negated.
For example, in WebKit (as of Safari 18.4), /[a[^a-z]]/v incorrectly matches 'b' and incorrectly fails to match '!'.
This can be worked around in Oniguruma-To-ES by converting e.g. [a[^a-z]] to (?:[a]|[^a-z]).
As identified in shikijs/shiki#1005, a WebKit bug results in nested negated character classes being treated as if they weren't negated.
For example, in WebKit (as of Safari 18.4),
/[a[^a-z]]/vincorrectly matches'b'and incorrectly fails to match'!'.This can be worked around in Oniguruma-To-ES by converting e.g.
[a[^a-z]]to(?:[a]|[^a-z]).