3 ms·
Yes, I did, and you did not provide a single example. You just said "“oh see, I can run some examples from page just fine. So everything's all right, I've got f
by wbond 13y ago
Yes, I did, and you did not provide a single example. You just said "“oh see, I can run some examples from page just fine. So everything's all right, I've got full Unicode!".
Taking the time to actually prove your point it useful. However, your recent example seems to be running fine on Python 3.3. You did not include any version info in your example output.
Python 3.3.0 (default, Mar 11 2013, 00:32:12)
[GCC 4.7.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> "öo̧"[1:]
'o̧'
>>>
I haven't run across any situations where Python 3.3 is doing wrong, which is why I am asking for some examples.
- lelf 13y ago3.3.2. No, it is not. Use 'o\u0308o\u0327'
- wbond 13y agoOh, I see the issue here. You are expecting the string class to function via graphemes rather than characters. It should be possible to implement grapheme support since character support is there, but I imagine the reverse is not true. A little googling turned this up. https://mail.python.org/pipermail/python-ideas/2013-July/021916.html https://mail.python.org/pipermail/python-ideas/2013-July/021...
- tekacs 13y agoTL;DR of parent comment here for those skimming: x = 'o\u0308o\u0327' len(x) == 4 x == "öo̧" x[:2] == "ö" x[2:] == "o̧" x[0] == x[2] == "o"