On Thu, Aug 26, 2010 at 09:51:10AM +0200, yy wrote:
2010/8/26 Kris Maglione <maglion...@gmail.com>:
It does not work that way in postscript and, as I already said in
another message, it does not work that way in forth, neither in toka
or raven. Would you mind explainning why your way is more logical? I
think it could get compicated once you introduce else or nested if
blocks.
It does work that way in forth. At least, the conditional comes just before
the if token (though the branches come after it).
Therefore, it does not work that way in forth. You can also say that
the "branch" (forth has no branches!) comes after the conditional. My
question stands: why your way is more logical? what makes it worth to
take a different approach from all the other stack based languages
which use blocks?
I never said it was more logical, I said I prefer it. But my
point was that in forth the conditional comes just before the if
token. That's the only part that interests me. I find it easier
to read than having to backtrack bast two code branches when I
come across the if token to find out what the condition was.
Please, don't tell is the forth way when it is not. In forth, IF only
takes one argument and is compiled to a conditional jump to THEN (or
ELSE).
How is that not a branch?
--
Kris Maglione
There's no sense being exact about something if you don't even know
what you're talking about.
--John von Neumann