New submission from Vladimir Rutsky: re module documentation says:
Match Objects always have a boolean value of :const:`True`, so that you can test whether e.g. :func:`match` resulted in a match with a simple if statement. which is confusing - matched objects have boolean value True, doesn't matched - False. ---------- assignee: docs@python components: Documentation messages: 173595 nosy: docs@python, vrutsky priority: normal severity: normal status: open title: re: Match Objects always have a boolean value of True versions: Python 2.7 _______________________________________ 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