This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author owentrigueros
Recipients ezio.melotti, mrabarnett, owentrigueros
Date 2021-10-13.09:10:37
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <[email protected]>
In-reply-to
Content
"\W" regex pattern, when used with `re.ASCII`, is expected to have the same behavior as "[^a-zA-Z0-9_]" (see [1]).

For example, the following `sub()` call

```
>>> re.sub('\W', '', '½ a', re.ASCII)
'½a'
```

should return the same as this one:

```
>>> re.sub('[^a-zA-Z0-9_]', '', '½ a', re.ASCII)
'a'
```

But it does not.

[1] https://docs.python.org/3/library/re.html#regular-expression-syntax
History
Date User Action Args
2021-10-13 09:10:37owentriguerossetrecipients: + owentrigueros, ezio.melotti, mrabarnett
2021-10-13 09:10:37owentriguerossetmessageid: <[email protected]>
2021-10-13 09:10:37owentrigueroslinkissue45458 messages
2021-10-13 09:10:37owentrigueroscreate