next up previous contents index
Next: Closure Up: Constitutive Principles of A++ Previous: ARS   Contents   Index


Lexical Scope

`Lexical Scope' defines the access to variables within functions. Variables within functions are either `lambda-bound' or `free'. The `lambda-bound' variables refer to arguments passed to the function.

The so-called `free' variables must have been defined in the inherited environment of the function. In a language with `Lexical Scope' a lambda abstraction inherits all variables from those abstractions in which it is defined.

\fbox{
\parbox{14.5cm}{
The values of these variables reflect the {\em time of...
... variables may be changed however and
keep their new values indefinitely!
}
}
`Lexical Scope' in A++ is coupled with indefinite extent in contrast to Pascal where 'Lexical Scope' is coupled with `limited extent'.

`Lexical Scope' regulates the access to variables in a lambda-abstraction by its context visible in the program text.



domain access counter Georg P. Loczewski 2004-03-05