- status: open --> accepted
- assigned_to: Bruce Korb
When reading UTF-8 string values with get, there are two scenarios. If locale is not set for Guile, we get question signs on the output. If locale is set (e.g. using (setlocale LC_ALL "") in the pseudo macro) garbage is produced. The patch attached seems to solve the issue given the locale is set. But now, the wide-string output of get is not accepted by some string functions. For example, (string-capitalize (get "utf8var")) crashes with an error message like:
ERROR: In procedure string-capitalize:
ERROR: Invalid read access of chars of wide string: "<utf-8 string="">"</utf-8>
The above error message is thrown by the undocumented libguile function scm_i_string_chars().
Autogen version is 5.8.16. Guile version is 2.2.2