New Alpha_(re)

Sat, 12 Apr 1997 17:54:31 -0400



You wrote:

>  * If statements and such now default to short-circuit operations.
>    This can still be switched to complete evaluation using
>    `--no-short-circuit', (*$B+*), or (*$no-short-circuit*).  With
>    `--standard-pascal' etc., the default becomes complete evaluation
>    and can be switched to short circuit using `--short-circuit',
>    (*$B-*), or (*$short-circuit*).
>
>    (It is done this way because the cases where a program relies 
>on
>    complete evaluation of Boolean expressions are very rare; functions
>    with side effects should not occur in such situations anyway because
>    you cannot rely on the order of evaluation.  OTOH, there are *many*
>    programs which rely on short circuit evaluation.)

I like to add that Extended Pascal has the or_else and and_then to force
short circuit evalutation.

A quite clean solution IMHO.

Groetjes,

Berend.


Berend de Boer (berend@compuserve.com)

HTML conversion by Lluís de Yzaguirre i Maura
Institut de Lingüística Aplicada - Universitat "Pompeu Fabra"
e-mail: de_yza@upf.es