summaryrefslogtreecommitdiff
path: root/lisp/array.el
diff options
context:
space:
mode:
authorKen Raeburn <raeburn@raeburn.org>2015-11-01 01:42:21 -0400
committerKen Raeburn <raeburn@raeburn.org>2015-11-01 01:42:21 -0400
commit39372e1a1032521be74575bb06f95a3898fbae30 (patch)
tree754bd242a23d2358ea116126fcb0a629947bd9ec /lisp/array.el
parent6a3121904d76e3b2f63007341d48c5c1af55de80 (diff)
parente11aaee266da52937a3a031cb108fe13f68958c3 (diff)
downloademacs-39372e1a1032521be74575bb06f95a3898fbae30.tar.gz
merge from trunk
Diffstat (limited to 'lisp/array.el')
-rw-r--r--lisp/array.el15
1 files changed, 4 insertions, 11 deletions
diff --git a/lisp/array.el b/lisp/array.el
index e60cbdfffc1..86f41529765 100644
--- a/lisp/array.el
+++ b/lisp/array.el
@@ -1,9 +1,9 @@
;;; array.el --- array editing commands for GNU Emacs
-;; Copyright (C) 1987, 2000-2013 Free Software Foundation, Inc.
+;; Copyright (C) 1987, 2000-2015 Free Software Foundation, Inc.
;; Author: David M. Brown
-;; Maintainer: FSF
+;; Maintainer: emacs-devel@gnu.org
;; Keywords: extensions
;; This file is part of GNU Emacs.
@@ -800,7 +800,7 @@ Return COLUMN."
(put 'array-mode 'mode-class 'special)
;;;###autoload
-(defun array-mode ()
+(define-derived-mode array-mode fundamental-mode "Array"
"Major mode for editing arrays.
Array mode is a specialized mode for editing arrays. An array is
@@ -863,9 +863,6 @@ take a numeric prefix argument):
\\[array-display-local-variables] Display the current values of local variables.
Entering array mode calls the function `array-mode-hook'."
-
- (interactive)
- (kill-all-local-variables)
(make-local-variable 'array-buffer-line)
(make-local-variable 'array-buffer-column)
(make-local-variable 'array-row)
@@ -888,13 +885,9 @@ Entering array mode calls the function `array-mode-hook'."
(+ (floor (1- array-max-column) array-columns-per-line)
(if array-rows-numbered 2 1)))
(message "")
- (setq major-mode 'array-mode)
- (setq mode-name "Array")
(force-mode-line-update)
(set (make-local-variable 'truncate-lines) t)
- (setq overwrite-mode 'overwrite-mode-textual)
- (use-local-map array-mode-map)
- (run-mode-hooks 'array-mode-hook))
+ (setq overwrite-mode 'overwrite-mode-textual))