--- gforth/stuff.fs 2006/05/07 05:46:47 1.51 +++ gforth/stuff.fs 2006/12/31 13:39:14 1.53 @@ -1,6 +1,6 @@ \ miscelleneous words -\ Copyright (C) 1996,1997,1998,2000,2003,2004,2005 Free Software Foundation, Inc. +\ Copyright (C) 1996,1997,1998,2000,2003,2004,2005,2006 Free Software Foundation, Inc. \ This file is part of Gforth. @@ -351,4 +351,26 @@ previous ' uw@ alias w@ ( addr -- u ) ' ul@ alias l@ ( addr -- u ) \ ' sw@ alias outfile ( file-id -- r:old-file-id ) + ]] outfile-id >r try to-outfile-id [[ ; immediate compile-only + +: outfile< ( r:old-file-id -- ) + 0 ]] literal recover endtry r> to-outfile-id throw [[ +; immediate compile-only + +: to-infile-id ( file-id -- ) + to infile-id ; + +: >infile ( file-id -- r:old-file-id ) + ]] infile-id >r try to-infile-id [[ ; immediate compile-only + +: infile< ( r:old-file-id -- ) + 0 ]] literal recover endtry r> to-infile-id throw [[ +; immediate compile-only