changeset 54583:4a88f2b2e26a

(calc-mode-map): Use mapc.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Fri, 26 Mar 2004 15:29:13 +0000
parents 91f663907945
children 6f766221b410
files lisp/calc/calc.el
diffstat 1 files changed, 9 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/calc/calc.el	Fri Mar 26 15:27:56 2004 +0000
+++ b/lisp/calc/calc.el	Fri Mar 26 15:29:13 2004 +0000
@@ -1,6 +1,6 @@
 ;;; calc.el --- the GNU Emacs calculator
 
-;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 ;; Author: David Gillespie <daveg@synaptics.com>
 ;; Maintainers: D. Goel <deego@gnufans.org>
@@ -733,13 +733,13 @@
     (define-key map "\M-\C-m" 'calc-last-args-stub)
     (define-key map "\C-j" 'calc-over)
 
-    (mapcar (lambda (x) (define-key map (char-to-string x) 'undefined))
-	    "lOW")
-    (mapcar (lambda (x) (define-key map (char-to-string x) 'calc-missing-key))
-	    (concat "ABCDEFGHIJKLMNPQRSTUVXZabcdfghjkmoprstuvwxyz"
-		    ":\\|!()[]<>{},;=~`\C-k\M-k\C-w\M-w\C-y\C-_"))
-    (mapcar (lambda (x) (define-key map (char-to-string x) 'calcDigit-start))
-	    "_0123456789.#@")
+    (mapc (lambda (x) (define-key map (char-to-string x) 'undefined))
+	  "lOW")
+    (mapc (lambda (x) (define-key map (char-to-string x) 'calc-missing-key))
+	  (concat "ABCDEFGHIJKLMNPQRSTUVXZabcdfghjkmoprstuvwxyz"
+		  ":\\|!()[]<>{},;=~`\C-k\M-k\C-w\M-w\C-y\C-_"))
+    (mapc (lambda (x) (define-key map (char-to-string x) 'calcDigit-start))
+	  "_0123456789.#@")
     map))
 
 (defvar calc-digit-map
@@ -2952,8 +2952,7 @@
     (if (eq calc-language 'big)
 	(setq s (concat s "\n"))
       (when calc-line-numbering
-	(aset s 0 ?1)
-	(aset s 1 ?:)))
+	(setq s (concat "1:" (substring s 2)))))
     (setcar (cdr entry) (calc-count-lines s))
     s))