Re:Fish shell 3.0
by eequah9L on Friday December 28, 2018 @07:44PM
(#18780804)
That usage doesn't get the weirdly specific error message though. It's only the Python2-ish statement that gets one.
[ Parent
| on HN ]
Re:Fish shell 3.0
by pseudalopex on Saturday December 29, 2018 @05:47PM
(#18786157)
What does someone want "print foo" to do if "print" is a different function?
What does someone want "print (1, 2)" to do if "print" is the built-in function? It prints a tuple in Python 2 and ints in Python 3.
I get that. So the Python 3 interpreter has to assume that when I say "print (1, 2)", I actually mean, print these two individual arguments.
If I say "print 'foo'" though, it recommends "print ('foo')", but doesn't go all the way to assume I actually meant that. There's a piece of code handling that special case that stops short of actually interpreting what I apparently mean.
The frustration around that was the original point.