On Wed, Dec 4, 2019 at 3:35 AM Ned Batchelder <ned@nedbatchelder.com> wrote:
On 12/4/19 3:11 AM, Serhiy Storchaka wrote:
Why the "<>" operator and the "L" suffix was removed?
Is this a serious question? Many things were removed in moving from Python 2 to Python 3. It was explicitly decided that 2->3 would contain breaking changes. If you recall, this caused a large amount of controversy. Why bring that on ourselves again?
It actually has a serious answer. It is quite easy to write straddling code that avoids using <> and L-suffixed integers -- in 2.7, there's basically no difference between ints and longs except that they are different types and you have to write isinstance(x, (int, long)) in some cases. This is not the case for u"" strings. Without them, it was found quite hard to write straddling code that uses unicode at all; the kludges around it were ugly and inefficient. That's why we brought them back. -- --Guido van Rossum (python.org/~guido) *Pronouns: he/him **(why is my pronoun here?)* <http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-c...>