|
|
|
|
|
by hibbelig
2100 days ago
|
|
Context objects need to be passed around, with dynamic scoping you do not need to. You would normally use dynamic scoping for certain global parameters that apply to a lot of operations. Unix shell scripts provide something similar to dynamic scoping with environment variables: If you write a shell script that sets LD_LIBRARY_PATH or TMPDIR, then all programs invoked from that shell script will inherit the values. And if your shell script calls another shell script, then that shell script can again set environment variables, and those are visible until it returns. I would say that environment variables have been a great success story, and folks aren't too confused. |
|