Static and Dynamic Policy
When designing a compiler, it is important to decide whether we choose a static policy or a dynamic policy.
- The Static policy lets the compiler decide when faced with an issue at compile time.
- The policy that allows the compiler to take the decision during runtime is called as Dynamic policy.
The scope is the major issue that has to be focused on while designing a programming language. A scope can either be static or dynamic.
- Static scope is used when the possibility to determine the scope of the variable declaration can be done just by analyzing the program.
- It is not possible to determine the scope of the declaration if a programming language uses Dynamic scope.
Reference Link