Lably
Skip to content

Evaluation strategy

Programming language evaluation rules

  • 27 min read
  • 5 chapters

Learn it on Lably

Just like in mathematics, evaluation is the process of finding the value corresponding to an expression.

The calling convention consists of the low-level platform-specific details of parameter passing.

Example

To illustrate, executing a function call f(a, b) may first evaluate the arguments a and b, store the results in references or memory locations ref_a and ref_b, then evaluate the function's body with those references passed in. This gives the function the ability to look up the original argument values passed in through dereferencing the parameters (some languages use specific operators to perform this), to modify them via assignment as if they were local variables, and to return values via the references. This is the call-by-reference evaluation strategy.

Sign in to keep reading

4 more chapters are free with a Lably account.

More in Computing and communication