X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fhost-c-call.lisp;h=409fd9fa8013890c280afa886cc0695429a15d13;hb=731d5dd65a7b94b5d49d1663d9b60c3a406ce38c;hp=4ad089a32096f35219b4aec6005bef79adb97f36;hpb=d1355f6b79af346f05cf21c18637e269e0b499a1;p=sbcl.git diff --git a/src/code/host-c-call.lisp b/src/code/host-c-call.lisp index 4ad089a..409fd9f 100644 --- a/src/code/host-c-call.lisp +++ b/src/code/host-c-call.lisp @@ -14,9 +14,8 @@ (define-alien-type-class (c-string :include pointer :include-args (to))) (define-alien-type-translator c-string () - (make-alien-c-string-type :to - (parse-alien-type 'char - (sb!kernel::make-null-lexenv)))) + (make-alien-c-string-type + :to (parse-alien-type 'char (sb!kernel:make-null-lexenv)))) (define-alien-type-method (c-string :unparse) (type) (declare (ignore type)) @@ -24,7 +23,7 @@ (define-alien-type-method (c-string :lisp-rep) (type) (declare (ignore type)) - '(or simple-base-string null (alien (* char)))) + '(or simple-string null (alien (* char)))) (define-alien-type-method (c-string :naturalize-gen) (type alien) (declare (ignore type)) @@ -37,7 +36,8 @@ `(etypecase ,value (null (int-sap 0)) ((alien (* char)) (alien-sap ,value)) - (simple-base-string (vector-sap ,value)))) + (simple-base-string (vector-sap ,value)) + (simple-string (vector-sap (coerce ,value 'simple-base-string))))) (/show0 "host-c-call.lisp 42")