From xemacs-m  Fri Jun 13 01:56:10 1997
Received: from altair.xemacs.org (steve@xemacs.miranova.com [206.190.83.19])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id BAA01614
	for <xemacs-beta@xemacs.org>; Fri, 13 Jun 1997 01:56:08 -0500 (CDT)
Received: (from steve@localhost)
	by altair.xemacs.org (8.8.5/8.8.5) id XAA02703;
	Thu, 12 Jun 1997 23:56:12 -0700
Mail-Copies-To: never
To: xemacs-beta@xemacs.org
Subject: Re: Ebola inflicted ispell?
References: <9706130450.AA22484@fornet.gvc.dec.com>
X-Url: http://www.miranova.com/%7Esteve/
X-Face: #!T9!#9s-3o8)*uHlX{Ug[xW7E7Wr!*L46-OxqMu\xz23v|R9q}lH?cRS{rCNe^'[`^sr5"
 f8*@r4ipO6Jl!:Ccq<xoV[Qz2u8<8-+Vwf2gzJ44lf_/y9OaQ`@#Q65{U4/TC)i2`~/M&QI$X>p:9I
 OSS'2{-)-4wBnVeg0S\O4Al@)uC[pD|+
X-Attribution: sb
From: Steve "Ebola Vaccinations R Us" Baur <steve@xemacs.org>
In-Reply-To: Steve Carney's message of "Fri, 13 Jun 1997 06:50:12 +0200"
Mime-Version: 1.0 (generated by tm-edit 7.108)
Content-Type: text/plain; charset=US-ASCII
Date: 12 Jun 1997 23:56:11 -0700
Message-ID: <m2iuzj3sac.fsf@altair.xemacs.org>
Lines: 159
X-Mailer: Gnus v5.4.56/XEmacs 20.3(beta7) - "Oslo"

Steve Carney <carney@gvc.dec.com> writes:

> In 20.3-b6, trying to ispell-buffer a few lines of text generates a slew
> of the following kind of message:

> [ispell-command-loop, byte-code, ispell-region, <compiled-function
>  from "ispell.elc">, call-interactively, command-execute, 
>  execute-extended-command, call-interactively]
>  Comparison between integer and character is constant nil (54 and ?i)

Yup, and it should cause failure of what it's trying to do too.
Please try this patch:

1997-06-12  Steven L Baur  <steve@altair.xemacs.org>

	* packages/ispell.el (ispell-command-loop): De-Ebolify.

Index: lisp/packages/ispell.el
===================================================================
RCS file: /usr/local/xemacs/xemacs-20.0/lisp/packages/ispell.el,v
retrieving revision 1.6
diff -u -r1.6 ispell.el
--- ispell.el	1997/04/16 04:07:50	1.6
+++ ispell.el	1997/06/13 06:51:16
@@ -1066,13 +1066,15 @@
 		     max-lines))
 	;; not so good if there are over 20 or 30 options, but then, if
 	;; there are that many you don't want to scan them all anyway...
+	(when (integerp count)
+	  (setq count (int-char count)))
 	(while (memq count command-characters) ; skip command characters.
-	  (setq count (1+ count)
+	  (setq count (int-char (1+ count))
 		skipped (1+ skipped)))
 	(insert "(" count ") " (car choices) "  ")
 	(setq choices (cdr choices)
 	      count (1+ count)))
-      (setq count (- count ?0 skipped)))
+      (setq count (int-char (- count ?0 skipped))))
 
     ;; Assure word is visible
     (if (not (pos-visible-in-window-p end))
@@ -1124,7 +1126,7 @@
 				   (read-char-exclusive)
 				 (read-char))
 			  skipped 0)
-		    (if (or quit-flag (= char ?\C-g)) ; C-g is like typing X
+		    (if (or quit-flag (eq char ?\C-g)) ; C-g is like typing X
 			(setq char ?X
 			      quit-flag nil)))
 		  ;; Adjust num to array offset skipping command characters.
@@ -1136,36 +1138,36 @@
 		    (setq num (- char ?0 skipped)))
 
 		  (cond
-		   ((= char ? ) nil)	; accept word this time only
-		   ((= char ?i)		; accept and insert word into pers dict
+		   ((eq char ? ) nil)	; accept word this time only
+		   ((eq char ?i)	; accept and insert word into pers dict
 		    (process-send-string ispell-process (concat "*" word "\n"))
 		    (setq ispell-pdict-modified-p '(t)) ; dictionary modified!
 		    nil)
-		   ((or (= char ?a) (= char ?A)) ; accept word without insert
+		   ((or (eq char ?a) (eq char ?A)) ; accept word without insert
 		    (process-send-string ispell-process (concat "@" word "\n"))
 		    (if (null ispell-pdict-modified-p)
 			(setq ispell-pdict-modified-p
 			      (list ispell-pdict-modified-p)))
-		    (if (= char ?A) 0))	; return 0 for ispell-add buffer-local
-		   ((or (= char ?r) (= char ?R)) ; type in replacement
-		    (if (or (= char ?R) ispell-query-replace-choices)
+		    (if (eq char ?A) 0)) ; return 0 for ispell-add buffer-local
+		   ((or (eq char ?r) (eq char ?R)) ; type in replacement
+		    (if (or (eq char ?R) ispell-query-replace-choices)
 			(list (read-string "Query-replacement for: " word) t)
 		      (cons (read-string "Replacement for: " word) nil)))
-		   ((or (= char ??)
+		   ((or (eq char ??)
 			;; XEmacs change: help-char may not be an int.
 			(eq char (event-to-character
 				  (character-to-event help-char)))
-			(= char ?\C-h))
+			(eq char ?\C-h))
 		    (ispell-help)
 		    t)
 		   ;; Quit and move point back.
-		   ((= char ?x)
+		   ((eq char ?x)
 		    (ispell-pdict-save ispell-silently-savep)
 		    (message "Exited spell-checking")
 		    (setq ispell-quit t)
 		    nil)
 		   ;; Quit and preserve point.
-		   ((= char ?X)
+		   ((eq char ?X)
 		    (ispell-pdict-save ispell-silently-savep)
 		    (message "%s"
 		     (substitute-command-keys
@@ -1174,7 +1176,7 @@
 		    (setq ispell-quit (max (point-min)
 					   (- (point) (length word))))
 		    nil)
-		   ((= char ?q)
+		   ((eq char ?q)
 		    (if (y-or-n-p "Really kill Ispell process? ")
 			(progn
 			  (ispell-kill-ispell t) ; terminate process.
@@ -1182,7 +1184,7 @@
 						(point))
 				ispell-pdict-modified-p nil))
 		      t))		; continue if they don't quit.
-		   ((= char ?l)
+		   ((eq char ?l)
 		    (let ((new-word (read-string
 				     "Lookup string (`*' is wildcard): "
 				     word))
@@ -1212,7 +1214,7 @@
 					       new-line)
 					     max-lines))
 				(while (memq count command-characters)
-				  (setq count (1+ count)
+				  (setq count (int-char (1+ count))
 					skipped (1+ skipped)))
 				(insert "(" count ") " (car choices) "  ")
 				(setq choices (cdr choices)
@@ -1235,12 +1237,12 @@
 				  (setq line new-line)))
 			    (select-window (next-window)))))
 		    t)			; reselect from new choices
-		   ((= char ?u)
+		   ((eq char ?u)
 		    (process-send-string ispell-process
 					 (concat "*" (downcase word) "\n"))
 		    (setq ispell-pdict-modified-p '(t)) ; dictionary modified!
 		    nil)
-		   ((= char ?m)		; type in what to insert
+		   ((eq char ?m)	; type in what to insert
 		    (process-send-string
 		     ispell-process (concat "*" (read-string "Insert: " word)
 					    "\n"))
@@ -1250,11 +1252,11 @@
 		    (if ispell-query-replace-choices ; Query replace flag
 			(list (nth num miss) 'query-replace)
 		      (nth num miss)))
-		   ((= char ?\C-l)
+		   ((eq char ?\C-l)
 		    (redraw-display) t)
-		   ((= char ?\C-r)
+		   ((eq char ?\C-r)
 		    (save-window-excursion (recursive-edit)) t)
-		   ((= char ?\C-z)
+		   ((eq char ?\C-z)
 		    (funcall (key-binding "\C-z"))
 		    t)
 		   (t (ding) t))))))

-- 
steve@calag.com baur
Unsolicited commercial e-mail will be billed at $250/message.

