diff options
Diffstat (limited to 'fun')
-rw-r--r-- | fun/wcl/wc.lisp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fun/wcl/wc.lisp b/fun/wcl/wc.lisp index a3d5cd120629..81576d41aa4c 100644 --- a/fun/wcl/wc.lisp +++ b/fun/wcl/wc.lisp @@ -12,7 +12,7 @@ (iter (for byte in-stream file-stream using #'read-byte) (for previous-byte previous byte) - (for is-newline = (eq newline byte)) + (for is-newline = (eql newline byte)) ;; Count each byte (sum 1 into bytes) @@ -22,12 +22,12 @@ ;; Count every "word", unless the preceding character already ;; was a space or we are at the beginning of the file. - (when (or (eq space previous-byte) - (eq newline previous-byte) + (when (or (eql space previous-byte) + (eql newline previous-byte) (not previous-byte)) (next-iteration)) - (counting (or is-newline (eq space byte)) + (counting (or is-newline (eql space byte)) into words) (declare (fixnum bytes newlines words)) |