Re:Dynamic Scoping in C++
by chrisseaton on Monday September 21, 2020 @03:01PM
(#24547099)
I'm not sure what you think is the important difference between these implementations?
'Dynamic binding' is an abstract concept. The abstract concept is a global variable with a stack of values. How you implement it and whether you share the call-stack instead of a separate stack is is up to you. It's still the same dynamic scoping.
Re:Dynamic Scoping in C++
by tlb on Monday September 21, 2020 @03:57PM
(#24547738)
Only one of them works with multiple threads. Dynamic scoping based on save-and-restore of symbol value slots is completely incompatible with multithreading. That's why Emacs still doesn't have threads.
'Dynamic binding' is an abstract concept. The abstract concept is a global variable with a stack of values. How you implement it and whether you share the call-stack instead of a separate stack is is up to you. It's still the same dynamic scoping.