I have a large data set that was converted from JSON data. It has unicode characters using the JSON-compliant \uXXXX notation. I'm trying to convert these to true unicode on the fly using preg_replace.
preg_replace('/\\u([a-z0-9]+)/i', "\x{${1}}", $str);
However, this generates a warning:
PHP Warning: preg_replace(): Compilation failed: PCRE does not support \L, \l, \N{name}, \U, or \u at offset 1
Why is preg_replace complaining when I'm searching for the actual slash-u and not a unicode literal?
Edit:
Here's what I'm working with: https://regex101.com/r/LIdECa/1