Hacker News new | past | comments | ask | show | jobs | submit login

Well, I don't entirely agree here; there are some valid concerns about Py3-specific design decisions. Take, for instance, conversion of `str` to Unicode. That

* significantly increases the memory footprint as every character requires 2-4 bytes to encode.

* does not provide 1-to-1 correspondence with certain Asian encodings.

* creates an impedance mismatch between Python and byte-oriented filesystem/internet protocols.

Personally, I believe total Unicodification in Py3 was worthwhile, but from some perspective, it could be seen as a regression.

That said, I'd love to hear what specifically in Py3 could cause such a burst of hate.




Python3 has the 'bytes' type, which can be used for the same things that 'str' was used for in Python 2.x . So you don't lose any functionality, just rename your types.

As an added bonus, the name 'bytes' makes it very clear, that you're dealing with raw data.

Strings have become a data-type solely for human-readable text. For these, it makes perfect sense to only support unicode.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: