home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
forth
/
compiler
/
fpc
/
source
/
editerr.seq
< prev
next >
Wrap
Text File
|
1990-11-12
|
1KB
|
32 lines
\ EDITERR.SEQ Automatically enter editor on compile error
defined ed nip 0= #if \s #endif \ if ED not defined, stop loading
only forth also definitions editor also
create msgsave 32 allot
create wordsave 32 allot
: (EDITERR) ( a1 n1 --- )
31 min dup msgsave c! msgsave 1+ swap cmove
>in @ 1- here c@ - 0MAX =: screenchar
tib screenchar + wordsave dup>r 1+
here c@ 31 min dup>r cmove r> r> c!
0 rows 1- at
30 here c@ msgsave c@ + 2/ - spaces ." █████> "
wordsave count type 2 spaces
msgsave count type ." <█████ "
edinit
rows 3 - save!> last.textline
?leave_set
<ed>
restore> last.textline
done quit ;
: autoediton ( --- )
['] (editerr) is doerror ;
: autoeditoff ( --- )
['] (doerror) is doerror ;