Use SELECT-BUFFER-NOT-FOUND-HOOKS to change behavior of C-x b so that
authorChris Hanson <org/chris-hanson/cph>
Wed, 30 Sep 1992 18:30:03 +0000 (18:30 +0000)
committerChris Hanson <org/chris-hanson/cph>
Wed, 30 Sep 1992 18:30:03 +0000 (18:30 +0000)
it always creates buffers that are associated with files.

v7/src/6001/edextra.scm

index f4fe466e10e2c9f0fe3be1e8f8b7e75caad60232..0fc648ba383b5db2dd48d4096c8d3077ec8da65a 100644 (file)
@@ -1,6 +1,6 @@
 #| -*-Scheme-*-
 
-$Id: edextra.scm,v 1.14 1992/09/25 01:04:06 cph Exp $
+$Id: edextra.scm,v 1.15 1992/09/30 18:30:03 cph Exp $
 
 Copyright (c) 1992 Massachusetts Institute of Technology
 
@@ -430,6 +430,13 @@ below.  Otherwise, answer \"no\" to use a different name.
             (insert-string reply-to point)
             (insert-newline point)))))))
 
+(set-variable! select-buffer-not-found-hooks
+              (cons (lambda (name)
+                      (find-file-noselect (merge-pathnames name
+                                                           working-directory)
+                                          true))
+                    (ref-variable select-buffer-not-found-hooks)))
+
 ;; Disable key bindings that exit the editor.
 ;; M-x logout is all the students should need.
 (define-key 'fundamental '(#\c-x #\c-c) false)