diff --git a/hemlock/cursor.lisp b/hemlock/cursor.lisp
index d90265bd5838f505295908179fa2eb7153024384..cf22693d697d4d74124c7d14617e9740ec18b27a 100644
--- a/hemlock/cursor.lisp
+++ b/hemlock/cursor.lisp
@@ -112,7 +112,9 @@
   (declare (fixnum width start end))
   (do ((xpos 0)
        (ypos 0)
-       (chars (line-chars line)) losing dy)
+       (chars (line-chars line))
+       (losing 0)
+       (dy 0))
       ((= start end) (values xpos ypos))
     (declare (fixnum xpos ypos losing dy) (simple-string chars))
     (setq losing (%fcwa chars start end losing-char))
@@ -138,7 +140,8 @@
 ;;;
 (defun cached-real-line-length (line width start end)
   (declare (fixnum width start end) (ignore line))
-  (let ((offset (- right-open-pos left-open-pos)) bound)
+  (let ((offset (- right-open-pos left-open-pos))
+	(bound 0))
     (declare (fixnum offset bound))
     (cond
      ((>= start left-open-pos)
@@ -149,7 +152,9 @@
       (setq bound end)))
     
     (do ((xpos 0)
-	 (ypos 0) losing dy)
+	 (ypos 0)
+	 (losing 0)
+	 (dy 0))
 	(())
       (declare (fixnum xpos ypos losing dy))
       (when (= start bound)
@@ -192,9 +197,10 @@
 	 (offset (mark-charpos start))
 	 (start-number (line-number (mark-line start)))
 	 (end (window-display-end window))
-	 (end-number (line-number (mark-line end))) ypos dis-line)
-    (declare (fixnum width charpos ypos number end-number)
-	     (simple-vector dis-lines))
+	 (end-number (line-number (mark-line end)))
+	 (ypos 0)
+	 dis-line)
+    (declare (fixnum width charpos ypos number end-number))
     (cond
      ((or (< number start-number)
 	  (and (= number start-number) (< charpos offset))