--- gforth/kernel/saccept.fs 2007/12/31 18:40:26 1.15 +++ gforth/kernel/saccept.fs 2010/12/31 18:09:02 1.19 @@ -1,6 +1,6 @@ \ a very simple accept approach -\ Copyright (C) 1995,1996,1997,1998,1999,2000,2003,2006 Free Software Foundation, Inc. +\ Copyright (C) 1995,1996,1997,1998,1999,2000,2003,2006,2007,2010 Free Software Foundation, Inc. \ This file is part of Gforth. @@ -43,4 +43,15 @@ Variable echo -1 echo ! over c! char+ ELSE r> drop bell THEN THEN AGAIN ; - + +\ simple include for terminal.fs + +: refill-loop ( -- ) + BEGIN 3 emit refill WHILE interpret REPEAT ; +: included ( addr u -- ) + 2 emit dup $20 + emit type + echo @ IF + echo off ['] refill-loop catch + dup IF 4 emit THEN echo on throw + THEN ; +: include ( "file" -- ) parse-name included ;