-;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10; Package: UFFI -*-
+;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10 -*-
;;;; *************************************************************************
;;;; FILE IDENTIFICATION
;;;;
(fast-native-to-string ,stored-obj ,length))))))
#+lispworks
- ;; FAST-NATIVE-TO-STRING (suprisingly) works just fine with UTF-8 multibyte character strings
+ #|
+ ;; FAST-NATIVE-TO-STRING (suprisingly) works just fine to make strings
+ ;; for formatted printing with Lispworks and UTF-8 multibyte character strings.
;; However, without knowledge of specific-encoding, the LENGTH call in FAST-NATIVE-TO-STRING
- ;; may not be incorrect for some encodings/strings.
+ ;; will be be incorrect for some encodings/strings and strings consist of octets rather
+ ;; than wide characters
;; This is a stop-gap until get tech support on why the below fails.
(let ((stored-obj (gensym "STR-")))
`(let ((,stored-obj ,obj))
(if (fli:null-pointer-p ,stored-obj)
nil
(fast-native-to-string ,stored-obj ,length))))
+ |#
+ #|
;; Below code doesn't work on tesing with LW 6.0 testing with a UTF-8 string.
;; fli:convert-from-foreign-string with :external-format of :UTF-8 doesn't
;; properly code multibyte characters.
-#|
+ |#
(let ((stored-obj (gensym "STR-"))
(fe (gensym "FE-"))
(ife (gensym "IFE-")))
:null-terminated-p ,null-terminated-p
:external-format (list ,ife :eol-style :lf))
(fast-native-to-string ,stored-obj ,length))))))
-|#
#+(or cmu scl)
(let ((stored-obj (gensym)))