News for hackers. Stuff that matters.
Re:Dynamic Scoping in C++ by tsimionescu on Monday September 21, 2020 @01:13PM (#24545922)
Basically for the same reason you would prefer RAII to new/delete. You can easily forget to change the value of a global variable back to its old value, whereas dynamic variable bindings automatically revert to their old values after you leave the scope of their declarations.

There are no comments on this comment yet.