Type mismatch in the expansion of (setf schar)

Bug #1668619 reported by Timofei Shatrov on 2017-02-28
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

Minimal example:

(defun weird-warning (str)
  (let ((copy (copy-seq str)))
    (setf (char copy 0) #\HIRAGANA_LETTER_SMALL_TU)))

Upon compiling the following warning appears:

    Derived type of SB-C::NEW-VALUE is
    conflicting with its asserted type

This does not happen in SBCL 1.3.3 but does happen in SBCL 1.3.8 and later.

The code works, but the warning trips SLIME per-function compilation and asdf:load-system.

Stas Boukarev (stassats) wrote :

This is actually
(defun foo (a)
  (setf (schar a 0) #\HIRAGANA_LETTER_SMALL_TU))

summary: - warning when trying to modify a string copied by COPY-SEQ with Unicode
- character
+ Type mismatch in the expansion of (setf schar)
Changed in sbcl:
status: New → Triaged
importance: Undecided → Medium
Stas Boukarev (stassats) wrote :

In 1ac88e72db13e6586b8ceebff468b1fa108178cb

Changed in sbcl:
status: Triaged → Fix Committed
Changed in sbcl:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers