mirror of
https://github.com/forth-ev/VolksForth.git
synced 2024-11-29 21:49:17 +00:00
Detect and message file-not-found condition in INCLUDE
This commit is contained in:
parent
d704e50d71
commit
6812352db3
@ -18,10 +18,14 @@
|
|||||||
dup 0= swap #cr = or IF 0 exit THEN
|
dup 0= swap #cr = or IF 0 exit THEN
|
||||||
i/o-status? IF 1 exit THEN -1 ;
|
i/o-status? IF 1 exit THEN -1 ;
|
||||||
|
|
||||||
|
| : i/o-status?abort i/o-status? 3 and IF c64cr
|
||||||
|
fload-dev @ dos-error abort THEN ;
|
||||||
|
|
||||||
| : freadline ( -- eof )
|
| : freadline ( -- eof )
|
||||||
fload-dev @ fload-2nd @ busin
|
fload-dev @ fload-2nd @ busin
|
||||||
|
i/o-status?abort
|
||||||
tib /tib bounds
|
tib /tib bounds
|
||||||
DO bus@ dup eol? under
|
DO bus@ i/o-status?abort dup eol? under
|
||||||
IF I c! ELSE drop THEN
|
IF I c! ELSE drop THEN
|
||||||
dup 0<
|
dup 0<
|
||||||
IF drop ELSE I + tib - #tib ! UNLOOP
|
IF drop ELSE I + tib - #tib ! UNLOOP
|
||||||
@ -35,9 +39,6 @@
|
|||||||
|
|
||||||
\ fload-open fload-close 30jun20pz
|
\ fload-open fload-close 30jun20pz
|
||||||
|
|
||||||
| : i/o-status?abort i/o-status? IF cr
|
|
||||||
fload-dev @ dos-error abort THEN ;
|
|
||||||
|
|
||||||
defer on-fload ' noop is on-fload
|
defer on-fload ' noop is on-fload
|
||||||
| : fload-open ( addr c -- )
|
| : fload-open ( addr c -- )
|
||||||
on-fload fload-dev @
|
on-fload fload-dev @
|
||||||
|
Loading…
Reference in New Issue
Block a user