[gforth] / gforth / history.fs  

gforth: gforth/history.fs

Diff for /gforth/history.fs between version 1.52 and 1.53

version 1.52, Sat May 5 17:27:40 2007 UTC version 1.53, Sat May 5 17:30:23 2007 UTC
Line 216 
Line 216 
 : save-cursor ( -- )  cursor@ curpos ! ;  : save-cursor ( -- )  cursor@ curpos ! ;
 : restore-cursor ( -- )  curpos @ cursor! ;  : restore-cursor ( -- )  curpos @ cursor! ;
 : .rest ( addr pos1 -- addr pos1 )  : .rest ( addr pos1 -- addr pos1 )
       key? ?EXIT
     restore-cursor 2dup type 2dup cur-correct ;      restore-cursor 2dup type 2dup cur-correct ;
 : .all ( span addr pos1 -- span addr pos1 )  : .all ( span addr pos1 -- span addr pos1 )
     key? IF  rdrop  EXIT  THEN      key? ?EXIT
     restore-cursor >r 2dup swap type 2dup swap cur-correct r> ;      restore-cursor >r 2dup swap type 2dup swap cur-correct r> ;
 : xback-restore ( u -- )  : xback-restore ( u -- )
     drop restore-cursor ;      drop key? ?EXIT
       restore-cursor ;
   
 \ In the following, addr max is the buffer, addr span is the current  \ In the following, addr max is the buffer, addr span is the current
 \ string in the buffer, and pos1 is the cursor position in the buffer.  \ string in the buffer, and pos1 is the cursor position in the buffer.


Generate output suitable for use with a patch program
Legend:
Removed from v.1.52  
changed lines
  Added in v.1.53

CVS Admin

Powered by ViewCVS 1.0-dev
(Powered by ViewCVS)

ViewCVS and CVS Help