Open
Description
Trying to form Unicode hex ranges in a regular expression causes a LoadError
:
julia> r"[\x{00A0}-\x{10FFFD}]"
yields
ERROR: LoadError: PCRE compilation error: range out of order in character class at offset 11
Stacktrace:
[1] error(s::String)
@ Base ./error.jl:33
[2] compile(pattern::String, options::UInt32)
@ Base.PCRE ./pcre.jl:155
[3] compile(regex::Regex)
@ Base ./regex.jl:82
[4] Regex(pattern::String, compile_options::UInt32, match_options::UInt32)
@ Base ./regex.jl:47
[5] Regex(pattern::String)
@ Base ./regex.jl:70
[6] var"@r_str"(__source__::LineNumberNode, __module__::Module, pattern::Any, flags::Vararg{Any})
@ Base ./regex.jl:119
in expression starting at REPL[45]:1
The result should be a regex that matches all Unicode codepoints from U+00A0
to U+10FFFD
.
Julia version: 1.7.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment