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

> The str/unicode fix was one of the driving factors for Python 3 to exist in the first place, and if you removed it, then what's the point?

The reason python 3 exists is that most python 2 code had latent unicode-related bugs that would only manifest when they were exposed to non-ascii data. The backwards-incompatible barrier between str and bytes was the solution the python 3 team chose for this problem; adopting utf-8 as the standard encoding would have been another solution which I claim would have been more backwards-compatible (essentially moving to the go/rust model, which prove that you don't necessarily need separate byte and character string types for correct unicode handling).




But not every 8-bit byte string is valid UTF-8 so that could still cause a world of pain.




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

Search: