Message75134
No, re.sub()'s documentation
(http://docs.python.org/library/re.html#re.sub)
makes it clear that \ followed by n in the replacement string is
interpreted.
To insert \ followed by n you have to double the \ inside the raw string
like this:
>>> re.sub('a', r'\\n', 'abba')
'\\nbb\\n'
>>> |
|
Date |
User |
Action |
Args |
2008-10-23 04:02:19 | gvanrossum | set | recipients:
+ gvanrossum, ezio.melotti |
2008-10-23 04:02:19 | gvanrossum | set | messageid: <1224734539.24.0.343051309866.issue4185@psf.upfronthosting.co.za> |
2008-10-23 04:02:18 | gvanrossum | link | issue4185 messages |
2008-10-23 04:02:18 | gvanrossum | create | |
|