points by esprehn 2 days ago | 0 comments
That's also possible in JS with __proto__. The prototypes of the classes in the chain can be mutated at runtime too. How to handle these cases is well understood for JITs though and python could do the same.
See also the warning here:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
And this related article:
[–] mirashii 2 days ago
[–] lefra 1 day ago
Modifying a variable that is read by another thread needs special care in all multithreaded languages I know. If you don't use a synchronization primitive to tell the other thread "hey, this thing here may have changed, read it again from memory"; the other thread is free to use its old value for as long as it whishes.