summaryrefslogtreecommitdiff
path: root/libguile/strports.h
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2010-01-07 11:00:37 +0100
committerLudovic Courtès <ludo@gnu.org>2010-01-07 11:10:35 +0100
commit7b0419128bce68f48a158292430ed4a7202aa1b1 (patch)
treeda697b566d45d144d2c23310ac34de7c29e60666 /libguile/strports.h
parent29bcdbb05948a5f12d2d8cb36a0c3c582e738be3 (diff)
downloadguile-7b0419128bce68f48a158292430ed4a7202aa1b1.tar.gz
Have string ports honor `%default-port-encoding'.
* libguile/strports.c (scm_i_mkstrport): Remove. (scm_mkstrport): Don't change the port's encoding to UTF-8; convert STR to the default port encoding. (scm_strport_to_string): Fix documentation & indentation. * libguile/strports.h (scm_i_mkstrport): Remove. * test-suite/lib.scm (exception:encoding-error): New variable. (format-test-name): Set `%default-port-encoding' to "UTF-8". * test-suite/tests/ports.test ("string ports")["%default-port-encoding is honored", "suitable encoding [latin-1]", "suitable encoding [latin-3]", "wrong encoding"]: New tests. * test-suite/tests/r6rs-ports.test ("7.2.11 Binary Output")["put-bytevector with UTF-16 string port", "put-bytevector with wrong-encoding string port"]: New tests. * test-suite/tests/reader.test (read-string): Set `%default-port-encoding' to `#f'. ("reading")["unprintable symbol"]: Use a string that doesn't contain zeros. * doc/ref/api-io.texi (String Ports): Document encoding issues with `call-with-output-string' and `with-output-to-string'.
Diffstat (limited to 'libguile/strports.h')
-rw-r--r--libguile/strports.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/libguile/strports.h b/libguile/strports.h
index d93266a12..3a9c3ec01 100644
--- a/libguile/strports.h
+++ b/libguile/strports.h
@@ -3,7 +3,7 @@
#ifndef SCM_STRPORTS_H
#define SCM_STRPORTS_H
-/* Copyright (C) 1995,1996,2000,2001,2002, 2006, 2008 Free Software Foundation, Inc.
+/* Copyright (C) 1995,1996,2000,2001,2002, 2006, 2008, 2010 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@@ -44,8 +44,6 @@ SCM_API scm_t_bits scm_tc16_strport;
SCM_API SCM scm_mkstrport (SCM pos, SCM str, long modes, const char * caller);
-SCM_INTERNAL SCM scm_i_mkstrport (SCM pos, const char *locale_str, size_t str_len,
- long modes, const char *caller);
SCM_API SCM scm_strport_to_string (SCM port);
SCM_API SCM scm_object_to_string (SCM obj, SCM printer);
SCM_API SCM scm_call_with_output_string (SCM proc);