Add new procedure EXIT-SCHEME to first exit the editor and then kill
authorChris Hanson <org/chris-hanson/cph>
Mon, 10 Feb 1992 12:02:48 +0000 (12:02 +0000)
committerChris Hanson <org/chris-hanson/cph>
Mon, 10 Feb 1992 12:02:48 +0000 (12:02 +0000)
Scheme.  This is a workaround for a problem that occurs when using
termcap and calling %EXIT from within the editor: the terminal
settings don't seem to be getting properly restored.

v7/src/edwin/editor.scm

index 3f70a0e1bd521cfde3cd1f19cc4e12935ed769f0..6fdced2b561fd826901b9a8d27bf4fb736136450 100644 (file)
@@ -1,6 +1,6 @@
 ;;; -*-Scheme-*-
 ;;;
-;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/editor.scm,v 1.212 1992/02/08 15:23:31 cph Exp $
+;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/editor.scm,v 1.213 1992/02/10 12:02:48 cph Exp $
 ;;;
 ;;;    Copyright (c) 1986, 1989-92 Massachusetts Institute of Technology
 ;;;
@@ -324,6 +324,9 @@ This does not affect editor errors or evaluation errors."
 
 (define (exit-editor)
   (within-continuation editor-abort reset-editor))
+
+(define (exit-scheme)
+  (within-continuation editor-abort %exit))
 \f
 (define (^G-signal)
   (let ((handler *^G-interrupt-handler*))