Message314146
This is roughly my use case:
zip( "ßx", [0.5, 0.3]) is [('ß', 0.5), ('x', 0.3)]
zip("ßx".upper(), [0.5, 0.3]) will be [('S', 0.5), ('S', 0.3)] in later
case you never get to see the value for 'x'.
At least my expectation was that lower and upper should preserve text
length. At least this seemed to be the case in python2.7
2018-03-20 15:28 GMT+02:00 INADA Naoki <report@bugs.python.org>:
>
> INADA Naoki <songofacandy@gmail.com> added the comment:
>
> Another example:
>
> >>> s = "ß"
> >>> len(s)
> 1
> >>> len(s.upper())
> 2
> >>> s.upper()
> 'SS'
> >>> ord(s)
> 223
>
>
> > This breaks unicode text matching.
>
> What do you talking about? re module?
>
> ----------
> nosy: +inada.naoki
>
> _______________________________________
> Python tracker <report@bugs.python.org>
> <https://bugs.python.org/issue33108>
> _______________________________________
> |
|
Date |
User |
Action |
Args |
2018-03-20 14:18:08 | Kiril Dimitrov | set | recipients:
+ Kiril Dimitrov, vstinner, ezio.melotti, methane |
2018-03-20 14:18:08 | Kiril Dimitrov | link | issue33108 messages |
2018-03-20 14:18:08 | Kiril Dimitrov | create | |
|