4 ms·
Scheme, which was an inspiration for JavaScript, works the same way Python does in this case. See page 57 of the spec: http://dspace.mit.edu/bitstream/handle/17
by ptx 5y ago
Scheme, which was an inspiration for JavaScript, works the same way Python does in this case. See page 57 of the spec:
http://dspace.mit.edu/bitstream/handle/1721.1/5600/AIM-848.pdf http://dspace.mit.edu/bitstream/handle/1721.1/5600/AIM-848.p...
That was written in 1985. If you're thinking of this as a mistake and waiting for it to be corrected, you're going to be waiting a long time.
Edit: Although it would be awesome if Python had extension functions like Kotlin, which would make this super easy to fix (either in your own code or the standard library). But that would require static typing to be more baked into the core language.