diff options
author | Andy Wingo <wingo@pobox.com> | 2011-01-07 09:08:58 -0800 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2011-01-07 09:18:41 -0800 |
commit | 4a655e50a3890da9cd453a0b2c83dacc2cfcc34e (patch) | |
tree | 050c60a5546fa5908ddcd6380f63e4c6eef6770a /libguile/ports.c | |
parent | 30c282bf93d7162fd8898a035ab60a3a556c5199 (diff) | |
download | guile-4a655e50a3890da9cd453a0b2c83dacc2cfcc34e.tar.gz |
use scm_from_latin1_symboln for string literals and load-symbol
* libguile/bytevectors.c:
* libguile/eval.c:
* libguile/goops.c:
* libguile/i18n.c:
* libguile/load.c:
* libguile/memoize.c:
* libguile/modules.c:
* libguile/ports.c:
* libguile/print.c:
* libguile/procs.c:
* libguile/programs.c:
* libguile/read.c:
* libguile/script.c:
* libguile/srfi-14.c:
* libguile/stacks.c:
* libguile/strings.c:
* libguile/throw.c:
* libguile/vm.c: Use scm_from_latin1_symboln to make symbols from string
literals, because they aren't in the user's locale -- they are in
ASCII, and we can optimize this case.
* libguile/vm-i-loader.c: Also use scm_from_latin1_symboln when loading
narrow symbols.
Diffstat (limited to 'libguile/ports.c')
-rw-r--r-- | libguile/ports.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libguile/ports.c b/libguile/ports.c index a9ba08e2e..5983ff23e 100644 --- a/libguile/ports.c +++ b/libguile/ports.c @@ -2233,11 +2233,11 @@ SCM_DEFINE (scm_port_conversion_strategy, "port-conversion-strategy", h = scm_i_get_conversion_strategy (port); if (h == SCM_FAILED_CONVERSION_ERROR) - return scm_from_locale_symbol ("error"); + return scm_from_latin1_symbol ("error"); else if (h == SCM_FAILED_CONVERSION_QUESTION_MARK) - return scm_from_locale_symbol ("substitute"); + return scm_from_latin1_symbol ("substitute"); else if (h == SCM_FAILED_CONVERSION_ESCAPE_SEQUENCE) - return scm_from_locale_symbol ("escape"); + return scm_from_latin1_symbol ("escape"); else abort (); @@ -2275,14 +2275,14 @@ SCM_DEFINE (scm_set_port_conversion_strategy_x, "set-port-conversion-strategy!", SCM_VALIDATE_OPPORT (1, port); } - err = scm_from_locale_symbol ("error"); + err = scm_from_latin1_symbol ("error"); if (scm_is_true (scm_eqv_p (sym, err))) { scm_i_set_conversion_strategy_x (port, SCM_FAILED_CONVERSION_ERROR); return SCM_UNSPECIFIED; } - qm = scm_from_locale_symbol ("substitute"); + qm = scm_from_latin1_symbol ("substitute"); if (scm_is_true (scm_eqv_p (sym, qm))) { scm_i_set_conversion_strategy_x (port, @@ -2290,7 +2290,7 @@ SCM_DEFINE (scm_set_port_conversion_strategy_x, "set-port-conversion-strategy!", return SCM_UNSPECIFIED; } - esc = scm_from_locale_symbol ("escape"); + esc = scm_from_latin1_symbol ("escape"); if (scm_is_true (scm_eqv_p (sym, esc))) { scm_i_set_conversion_strategy_x (port, |