R. David Murray added the comment: Since the quoted paragraph is distant from where the information about the ``None`` return is documented, the wording of the quoted paragraph can be improved to make this clearer:
Match Objects always have a boolean value of ``True``. Since ``None`` (which has a boolean value of ``False``) is returned when there is no match, you can test whether there was a match with a simple ``if`` statement. ---------- nosy: +r.david.murray versions: +Python 3.2, Python 3.3, Python 3.4 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue16304> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com