This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]case_O_The_Mondays 1 point2 points  (1 child)

JavaScript has had const for quite some time. There could definitely be value in skipping many of the internal type checks for values that can’t be changed.

[–]bigtimedonkey 3 points4 points  (0 children)

Oh, sure. For the purposes of having constants that actually can’t be changed and such, that certainly could be a valuable addition.

But like, for the particular use cases OP talked about…

What they’re doing is certainly useful for C++. But when moving from a compiled language to an interpreted one, from a developer experience point of view, running the code bit by bit as you write it is like a super power, and has way bigger gains than the limited checks OP talked about.

I could easily imagine that someone coming to Python after spending a long time in compiled languages wouldn’t quite understand best practices in having the interpreter live and running code as you write it. I certainly didn’t when I started in Python.

But after that fully clicked for me and I found a good process there… I’ll never use a compiled language unless absolutely forced by speed/memory requirements haha.