!* -*-TECO-*- ! !~Filename~:! !LEDIT Package for Scheme.! SCHEDIT !& SCHEDIT Library Loaded:! !S Flag! PUH !^R SCHEDIT Zap Region:! !^R Send the region to Scheme.! 1:m(m.m^R_SCHEDIT_Zap_Defun) !^R SCHEDIT Zap Defun:! !^R Send a Defun to Scheme Appends the defun to buffer *SEDIT*. ^R SCHEDIT Resume Lisp will write out the buffer to _SEDIT > on ITS or _SCHEDIT.LSP.0 on Twenex. With a numeric argument, as in ^R Autoargument1 ^R SCHEDIT Zap Defun, zaps the region instead.! [0 !* Temporary.! [C[L[B[D f[dfile [Previous_Buffer .:\u0 fn0j !* Remember to return here to this point! QBuffer_NameuB !* in this buffer.! FF"N .,:FXC !* If given an arg, zap the region.! :iLRegion' !* Else zap the defun.! "# :cw @m(m.m ^R_Beginning_of_Defun) !* Jump to head of defun,! :XL !* Get first line for information.! FLXC' !* Get sexp into C.! m(m.mSelect_Buffer)*SCHEDIT* !* Append the code to this buffer.! gC !* Insert the code.! 2 :i*CFsEchoDisp !* Clear echo area.! @ft Zapping_L... 0FsEchoActive !* Make it stay.! qBm(m.mSelect_Buffer) !* Go back to original buffer! 0 !* Return, no change to buffer! !^R SCHEDIT Resume Lisp:! !^R Go back into Lisp, giving it any zapped defuns. (See ^R SCHEDIT Zap Defun.) Saves the current buffer, if changed.! !* First writes out the *SCHEDIT* buffer into a temporary file which the Lisp should read back in.! [H[B[F [Previous_Buffer 0fo..Q SCHEDIT_Lisp_JNamef"e w 1,f Name_of_Lisp:_f(( )m.v SCHEDIT_Lisp_JNamew) '[0 !* Write out the *SCHEDIT* buffer.! QBuffer_Filenam"E ET DSK:FOO.SCM' m(m.m^R_Save_File) QBuffer_NameuB m(m.mSelect_Buffer)*SCHEDIT* fsosteco"e !* On ITS,! fsmsname:f6uH !* Get MSNAME in qH as string! ! 0' !* Resume Lisp.! "# !* On Twenex,! fsmsnameuH !* Get MSNAME in qH as string! :iFH_SCHEDIT.LSP 1:<@ed F.-2> !* Expunge earliest version.! m(m.mWrite_File)F.0 0î ' !* Resume LISP! HK0fsModified !* Delete the old stuff.! !* This happens when they continue the Emacs.! QBm(m.mSelect_Buffer) !* We now return you to your! !* regular buffer! @v !* Redisplay (just in case)! 0 !* Return, no change to buffer!