Changeset 5333


Ignore:
Timestamp:
Oct 9, 2006, 3:34:14 PM (18 years ago)
Author:
Gary Byers
Message:

Write #\Sub's char-code if we can't encode a character in (implicit) iso-8859-1.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ccl/level-1/l1-streams.lisp

    r5329 r5333  
    17871787    (if (< code 256)
    17881788      (%ioblock-write-u8-element ioblock code)
    1789       (error "Character ~s can't be encoded on ~s" char (ioblock-stream ioblock)))))
     1789      (%ioblock-write-u8-element ioblock (char-code #\Sub)))))
    17901790
    17911791(defun %private-ioblock-write-char (ioblock char)
     
    18331833        (limit (ioblock-literal-char-code-limit ioblock))
    18341834        (encode-function (ioblock-encode-output-function ioblock))
    1835         (wcf (ioblock-write-char-when-locked-function ioblock))
    18361835        (start-char start-char (1+ start-char)))
    18371836       ((= i num-chars) (setf (ioblock-charpos ioblock) col) num-chars)
     
    18401839           (code (char-code char)))
    18411840      (declare (type (mod #x110000) code))
    1842       (cond ((eq char #\newline)
    1843              (setq col 0)
    1844              (funcall wcf ioblock char))
    1845             (t
    1846              (incf col)
    1847              (if (< code limit)
     1841      (if (eq char #\newline)
     1842        (setq col 0)
     1843        (incf col))
     1844      (if (< code limit)
    18481845               (%ioblock-write-u8-element ioblock code)
    1849                (funcall encode-function char #'%ioblock-write-u8-element ioblock)))))))
     1846               (funcall encode-function char #'%ioblock-write-u8-element ioblock)))))
     1847
    18501848
    18511849(declaim (inline %ioblock-write-u16-encoded-char))
Note: See TracChangeset for help on using the changeset viewer.