aboutsummaryrefslogtreecommitdiff
path: root/amforth-6.5/common/lib/exception.frt
blob: d9f7a8711dd793fe9784e4852eab1d676c4c5138 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15


\ allocate an exception number
\ is less than -4096, keeps track in EEPROM

-4096 Evalue exception
: exception ( -- n ) exception dup 1- to exception ;

\ usage
\ the code sequence
\  exception constant !!foo
\   ... if !!foo throw then ...
\ prints 
\ ?? -4096
\ and returns to the command prompt if not catched