Correct syntax for pathological re.search()
Karsten Hilbert
Karsten.Hilbert at gmx.net
Wed Oct 9 14:06:10 EDT 2024
Am Tue, Oct 08, 2024 at 04:59:48PM -0400 schrieb Alan Bawden via Python-list:
> Karsten Hilbert <Karsten.Hilbert at gmx.net> writes:
>
> Python 3.11.2 (main, Aug 26 2024, 07:20:54) [GCC 12.2.0] on linux
> Type "help", "copyright", "credits" or "license" for more information.
> >>> tex = '\sout{'
> >>> tex
> '\\sout{'
> >>>
>
> Am I missing something ?
>
> You're missing the warning it generates:
>
> <stdin>:1: DeprecationWarning: invalid escape sequence '\s'
I knew it'd be good to ask :-D
Karsten
--
GPG 40BE 5B0E C98E 1713 AFA6 5BC0 3BEA AC80 7D4F C89B
More information about the Python-list
mailing list