Message152194
| Author |
sjmachin |
| Recipients |
sjmachin |
| Date |
2012年01月28日.22:28:53 |
| SpamBayes Score |
4.4485583e-05 |
| Marked as misclassified |
No |
| Message-id |
<1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Expected behaviour illustrated using "C":
>>> import re
>>> re.findall(r'[\C]', 'CCC')
['C', 'C', 'C']
>>> re.compile(r'[\C]', 128)
literal 67
<_sre.SRE_Pattern object at 0x01FC6E78>
>>> re.compile(r'C', 128)
literal 67
<_sre.SRE_Pattern object at 0x01FC6F08>
Incorrect behaviour exhibited by "A" (and by "B" and
Z"):
>>> re.findall(r'[\A]', 'AAA')
[]
>>> re.compile(r'A', 128)
literal 65
<_sre.SRE_Pattern object at 0x01FC6F98>
>>> re.compile(r'[\A]', 128)
in
at at_beginning_string #### FAIL ####
<_sre.SRE_Pattern object at 0x01FDF0B0>
>>>
Also there is no self-checking at runtime; the switch default has a comment to the effect that nothing can be done, so pretend that the unknown opcode matched nothing. Zen? |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2012年01月28日 22:28:54 | sjmachin | set | recipients:
+ sjmachin |
| 2012年01月28日 22:28:53 | sjmachin | set | messageid: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> |
| 2012年01月28日 22:28:53 | sjmachin | link | issue13899 messages |
| 2012年01月28日 22:28:53 | sjmachin | create |
|