Xiang Zhang added the comment:

I don't think no need to swap. The current doc is right.

>>> re.findall(r'\W+', 'abcd123_#@@@@')
['#@@@@']
>>> re.findall(r'\w+', 'abcd123_#@@@@')
['abcd123_']

It's apparent that \w match alphanumeric and \W vice versa.

----------
nosy: +xiang.zhang

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27116>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to