From: Stephen Adams Date: Wed, 26 Apr 1995 03:23:03 +0000 (+0000) Subject: Fiddled with a sequence of definitions and expressions to ensure the X-Git-Tag: 20090517-FFI~6392 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=5b7f5586f09cb43ecc893e78888f8037412dcc2d;p=mit-scheme.git Fiddled with a sequence of definitions and expressions to ensure the last form is an expression to comply with the new analchecking software. --- diff --git a/v7/src/edwin/fileio.scm b/v7/src/edwin/fileio.scm index 8c7bce9b8..ec4bd049e 100644 --- a/v7/src/edwin/fileio.scm +++ b/v7/src/edwin/fileio.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: fileio.scm,v 1.124 1995/01/31 19:35:11 cph Exp $ +;;; $Id: fileio.scm,v 1.125 1995/04/26 03:22:49 adams Exp $ ;;; ;;; Copyright (c) 1986, 1989-95 Massachusetts Institute of Technology ;;; @@ -260,32 +260,12 @@ after you find a file. If you explicitly request such a scan with (define initialize-buffer-local-variables!) (let () -(set! initialize-buffer-local-variables! -(named-lambda (initialize-buffer-local-variables! buffer find-file?) - (let ((end (buffer-end buffer))) - (let ((start - (with-text-clipped - (mark- end (ref-variable local-variable-search-limit) 'LIMIT) - end - (lambda () (backward-one-page end))))) - (if start - (if (re-search-forward "Edwin Variables:[ \t]*" start end true) - (let ((start (re-match-start 0)) - (end (re-match-end 0))) - (if (or (not find-file?) - (not (ref-variable inhibit-local-variables buffer)) - (prompt-for-confirmation? - (string-append - "Set local variables as specified at end of " - (file-namestring (buffer-pathname buffer))))) - (parse-local-variables buffer start end))))))))) - (define edwin-environment (->environment '(edwin))) (define (evaluate sexp) (scode-eval (syntax sexp edwin-syntax-table) edwin-environment)) - + (define (parse-local-variables buffer start end) (let ((prefix (extract-string (line-start start 0) start)) (suffix (extract-string end (line-end end 0)))) @@ -346,8 +326,26 @@ after you find a file. If you explicitly request such a scan with (loop m4)))))))) (loop start)))) - -) + +(set! initialize-buffer-local-variables! +(named-lambda (initialize-buffer-local-variables! buffer find-file?) + (let ((end (buffer-end buffer))) + (let ((start + (with-text-clipped + (mark- end (ref-variable local-variable-search-limit) 'LIMIT) + end + (lambda () (backward-one-page end))))) + (if start + (if (re-search-forward "Edwin Variables:[ \t]*" start end true) + (let ((start (re-match-start 0)) + (end (re-match-end 0))) + (if (or (not find-file?) + (not (ref-variable inhibit-local-variables buffer)) + (prompt-for-confirmation? + (string-append + "Set local variables as specified at end of " + (file-namestring (buffer-pathname buffer))))) + (parse-local-variables buffer start end)))))))))) ;;;; Output diff --git a/v7/src/edwin/motion.scm b/v7/src/edwin/motion.scm index d81199637..cb766de16 100644 --- a/v7/src/edwin/motion.scm +++ b/v7/src/edwin/motion.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: motion.scm,v 1.86 1994/09/08 20:34:04 adams Exp $ +;;; $Id: motion.scm,v 1.87 1995/04/26 03:23:03 adams Exp $ ;;; ;;; Copyright (c) 1985, 1989-93 Massachusetts Institute of Technology ;;; @@ -79,20 +79,6 @@ (define mark-) (let () -(set! mark+ -(named-lambda (mark+ mark n #!optional limit?) - (let ((limit? (and (not (default-object? limit?)) limit?))) - (cond ((fix:positive? n) (%mark+ mark n limit?)) - ((fix:negative? n) (%mark- mark (fix:- 0 n) limit?)) - (else mark))))) - -(set! mark- -(named-lambda (mark- mark n #!optional limit?) - (let ((limit? (and (not (default-object? limit?)) limit?))) - (cond ((fix:positive? n) (%mark- mark n limit?)) - ((fix:negative? n) (%mark+ mark (fix:- 0 n) limit?)) - (else mark))))) - (define (%mark+ mark n limit?) (let ((group (mark-group mark)) (new-index (fix:+ (mark-index mark) n))) @@ -107,6 +93,20 @@ (limit-mark-motion limit? (group-start-mark group)) (make-mark group new-index)))) +(set! mark+ +(named-lambda (mark+ mark n #!optional limit?) + (let ((limit? (and (not (default-object? limit?)) limit?))) + (cond ((fix:positive? n) (%mark+ mark n limit?)) + ((fix:negative? n) (%mark- mark (fix:- 0 n) limit?)) + (else mark))))) + +(set! mark- +(named-lambda (mark- mark n #!optional limit?) + (let ((limit? (and (not (default-object? limit?)) limit?))) + (cond ((fix:positive? n) (%mark- mark n limit?)) + ((fix:negative? n) (%mark+ mark (fix:- 0 n) limit?)) + (else mark))))) + ) ;;;; Motion by Lines