[Python-Dev] SRE incompatibility

Fredrik Lundh Fredrik Lundh" <effbot@telia.com
Fri, 30 Jun 2000 16:18:13 +0200


my latest changes fixed a couple of things, but broke
one of the old RE tests, namely:

    re.match('\\x00ffffffffffffff', '\377') !=3D None

or in other words, long hexadecimal escapes are cast
down to 8-bit characters in RE.

in SRE (after the latest change), they're cast down to
the size of the engine's internal word size (currently 16
bits).

is the old behaviour worth keeping?  I'd rather not make
the engine dependent on string types; it shouldn't really
matter if you're using unicode patterns on 8-bit target
strings, or vice versa.

</F>