comparison lisp/files.el @ 6546:8eb722515c31

(set-visited-file-name): Kill local var vc-mode. Make buffer writable if was read-only due to vc.
author Richard M. Stallman <rms@gnu.org>
date Sun, 27 Mar 1994 19:49:47 +0000
parents f5abd5d777eb
children f0e1ed0e82a7
comparison
equal deleted inserted replaced
6545:3715d5bfad50 6546:8eb722515c31
1182 ;; Changing to visit an ordinary local file instead should flush the hook. 1182 ;; Changing to visit an ordinary local file instead should flush the hook.
1183 (kill-local-variable 'write-file-hooks) 1183 (kill-local-variable 'write-file-hooks)
1184 (kill-local-variable 'local-write-file-hooks) 1184 (kill-local-variable 'local-write-file-hooks)
1185 (kill-local-variable 'revert-buffer-function) 1185 (kill-local-variable 'revert-buffer-function)
1186 (kill-local-variable 'backup-inhibited) 1186 (kill-local-variable 'backup-inhibited)
1187 ;; If buffer was read-only because of version control,
1188 ;; that reason is gone now, so make it writable.
1189 (if vc-mode
1190 (setq buffer-read-only nil))
1191 (kill-local-variable 'vc-mode)
1187 ;; Turn off backup files for certain file names. 1192 ;; Turn off backup files for certain file names.
1188 ;; Since this is a permanent local, the major mode won't eliminate it. 1193 ;; Since this is a permanent local, the major mode won't eliminate it.
1189 (and (not (funcall backup-enable-predicate buffer-file-name)) 1194 (and (not (funcall backup-enable-predicate buffer-file-name))
1190 (progn 1195 (progn
1191 (make-local-variable 'backup-inhibited) 1196 (make-local-variable 'backup-inhibited)