[Ecls-list] UFFI and unicode

Waldek Hebisch hebisch at math.uni.wroc.pl
Sat May 9 22:12:54 UTC 2009


I have noticed that in Unicode enabled ECL with-cstring fails
when given a Lisp string -- it wants only a base-string.

For example, the following fails:

(FFI:DEF-FUNCTION ("puts" G130) ((G129 :CSTRING)) :RETURNING :INT)
(DEFUN FOO (ST) (FFI:WITH-CSTRING (G129 ST) (G130 G129)))
(foo (make-string 8 :initial-element #\.))

with message:

In function MAKE-FOREIGN-DATA-FROM-ARRAY, the value of argument is
        "........"
which is not of expected type BASE-STRING


Is this intended behavoiur?

BTW: with-cstring works fine if I coerce argunent to base-string.

-- 
                              Waldek Hebisch
hebisch at math.uni.wroc.pl 




More information about the ecl-devel mailing list