[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mathematical models




"Guillermo J. Rozas" <gjr@martigny.ai.mit.edu> writes:

> It might be wise these days to mandate the order of argument
> evaluation to be left-to-right, but I have a hard time believeing that
> this is an important issue (especially vis-a-vis records, exceptions,
> etc.).

I remember when Yale released a new version of T which included David
Kranz's new compiler.  The intepreter evaluated combinations in the
same order as the original compiler, but the new compiler used the
reverse order.  We found a variety of obscure bugs in code written by
people who knew that the order was unspecified.  (I was one of the
guilty parties.)  The code worked when interpreted and failed when
compiled.  That experience convinced me that having an unspecified
order of evaluation in an expression oriented language is an
invitation for trouble.  To be honest, I also favor specifying the
order of evaluation for theoretical reasons as well.

John