[issue24071] Python 2.7.8, 2.7.9 re.MULTILINE failure

2015-12-28 Thread Ezio Melotti
Ezio Melotti added the comment: See #11957. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyt

[issue24071] Python 2.7.8, 2.7.9 re.MULTILINE failure

2015-05-01 Thread R. David Murray
R. David Murray added the comment: It is, however, frequently reported as a bug, if that makes you feel any better :) -- nosy: +r.david.murray ___ Python tracker ___ ___

[issue24071] Python 2.7.8, 2.7.9 re.MULTILINE failure

2015-04-28 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Pytho

[issue24071] Python 2.7.8, 2.7.9 re.MULTILINE failure

2015-04-28 Thread Matthew Barnett
Matthew Barnett added the comment: The 4th argument of re.sub is the maximum count (0 means unlimited). >>> help(re.sub) Help on function sub in module re: sub(pattern, repl, string, count=0, flags=0) Return the string obtained by replacing the leftmost non-overlapping occurrences of th

[issue24071] Python 2.7.8, 2.7.9 re.MULTILINE failure

2015-04-28 Thread Stephen Evans
New submission from Stephen Evans: A simple multiline regex fails when just the re.MULTILINE argument is used, but works when equivalent alternative methods are used. This was tested on Python2.7.8 on FreeBSD and Win32 Python2.7.9 data = re.sub(r'#.*', '', text, re.MULTILINE) # fails data = r