mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-27 19:18:06 +11:00
3d908cef3a
This allows us to get rid of the (parse*) indirection.
11 lines
174 B
Plaintext
11 lines
174 B
Plaintext
( returns negative value on error )
|
|
: _ ( c -- n )
|
|
( '0' is ASCII 48 )
|
|
48 -
|
|
DUP 0< ( bad ) OVER 2 < ( good ) OR IF EXIT THEN
|
|
( bad )
|
|
255 -
|
|
;
|
|
|
|
|