[issue29291] Misleading text in the documentation of re library for non-greedy match

2017-01-17 Thread Raymond Hettinger
Raymond Hettinger added the comment: I concur with Serhiy and Xiang that the docs are correct as-is. Also IMO, the proposed rewording will cause more confusion than it cures. Since this issue hasn't previously come up in the rather long life span of the re module, it suggests that most

[issue29291] Misleading text in the documentation of re library for non-greedy match

2017-01-17 Thread Xiang Zhang
Xiang Zhang added the comment: This doesn't look like a bug in the doc to me. -- nosy: +xiang.zhang ___ Python tracker ___

[issue29291] Misleading text in the documentation of re library for non-greedy match

2017-01-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The documentation doesn't look incorrect to me. The non-greedy match doesn't fallback to the greedy match, it always matches as few characters as *possible* will be matched. For example a.match(" b e ") matches " b ", not " b e ". -- nosy:

[issue29291] Misleading text in the documentation of re library for non-greedy match

2017-01-17 Thread ipolcak
New submission from ipolcak: The text about non-greedy match in the documentation for re library is misleading. The docs for py2.7 (https://docs.python.org/2.7/library/re.html) and 3.6 (https://docs.python.org/3.6/library/re.html) says: "The '*', '+', and '?' qualifiers are all greedy; they