6 ms·
My claim there was only that it was reified in memory, not that in the case of loading x, you had to use it. Though it is worth noting that you dont. In genera
by mjburgess 6y ago
My claim there was only that it was reified in memory, not that in the case of loading x, you had to use it. Though it is worth noting that you dont.
In general the point stands, the reason for slowness is indirection & reification. (Not sure why i'm downvoted).
- jashmatthews 6y agoThe locals dict is lazily created from the locals in the stack frame. No dict there unless you use it. The article I linked to before has a really good explanation of this. len() only causes one dictionary lookup and then it's cached. > This is necessary, in general, to deliver on the dynamic lang. features python provides. It's the most obvious way to implement these features of dynamic languages but not at all necessary. https://www.infoworld.com/article/2074780/avoiding-hash-lookups-in-a-ruby-implementation.html https://www.infoworld.com/article/2074780/avoiding-hash-look... https://bibliography.selflanguage.org/_static/pics.pdf https://bibliography.selflanguage.org/_static/pics.pdf