Liste des Groupes | Revenir à cl forth |
On Sun, 4 May 2025 13:33:31 +0000, Anton Ertl wrote:
>dxf <dxforth@gmail.com> writes:[..]On 4/05/2025 2:02 am, Anton Ertl wrote:dxf <dxforth@gmail.com> writes:In iForth 5.1-mini QUIT preserves the stack while an uncaught -56>
THROW resets it to empty (as it should); the uncaught -56 THROW does
not produce a message. For the cases with CATCH, the FOO variant does
not put the -56 on the stack and does not text-interpret the 5
afterwards, but it does preserve the 2 that was pushed earlier.
Strange. The BAR variant behaves as expected. If I try
>
2 : foo 3 1 throw ; ' foo catch 5
..s
>
iForth 5.1-mini behaves as follows:
>
FORTH> 2 : foo 3 1 throw ; ' foo catch 5 ok
[3]FORTH> .s
Data: 2 1 5 ---
System: ---
Float: --- ok
>
This is expected, so it seems to do something special for -56 THROW.
Searching for: -56 THROW
D:\dfwforth\examples\misc\risky-program.frt(3): \ A heated debate is
possible over the exact action -56 THROW should have. Should it QUIT ?
D:\dfwforth\examples\misc\risky-program.frt(57): 2: 1999 12 [ -56 throw
-56 THROW executed
Found 3 occurrence(s) in 1 file(s), 39514 ms
>
There must have been a convincing reason.
>Example snipped.
-marcel
>
Les messages affichés proviennent d'usenet.