Hi, Eli Zaretskii <[email protected]> writes:
>> From: Christopher Lam <[email protected]> >> Date: Tue, 16 Apr 2019 04:13:14 +0000 >> >> I'm struggling with string-ports on Windows. > > Which version of Guile are you using, and where/how did you obtain the > Windows binary? > >> Last para of >> https://www.gnu.org/software/guile/manual/html_node/String-Ports.html >> "With string ports, the port-encoding is treated differently than other >> types of ports. When string ports are created, they do not inherit a >> character encoding from the current locale. They are given a default locale >> that allows them to handle all valid string characters." >> >> This causes a string-sanitize function to not run correctly in Windows. >> (locale-encoding) says "CP1252" no matter what LANG or setlocale I try. >> >> The use case is to sanitize string for html, but on Windows it munges >> extended-unicode. > > Can you show the code that doesn't work for you as you expected? At > least the example in "String Ports" seems to work for me as I'd > expect, with Guile 2.0.11. The change in string ports that Christopher is referring to was first introduced in Guile 2.2.0. Mark
