[fpc-pascal] if-then-else expression
Michael Schnell
mschnell at lumino.de
Tue Feb 2 10:25:52 CET 2016
On 02/01/2016 09:35 PM, Maciej Izak wrote:
>
>
> x := if true then 0 else 1
Here a keyword and a statement just optionally returns a value, Same is
ignored in all legacy code but can be use it you want to and do know
what you do.
Additionally "0" now is a statement, (optionally) extending what is
considered a statement.
This is a rather drastic change in the basic definition of the language,
but might be doable. I's completely optional, and I don't see how it
might break anything.
But of course the paradigm would ask for being extended to many or all
other keywords.
An obvious example is "case".
-Michael
More information about the fpc-pascal
mailing list