diff options
author | Kenichi Handa <handa@m17n.org> | 2007-12-05 05:07:51 +0000 |
---|---|---|
committer | Kenichi Handa <handa@m17n.org> | 2007-12-05 05:07:51 +0000 |
commit | e93abe3da7f18b44aad0aa302f15f6777c7d1627 (patch) | |
tree | f82d1c3a970c6bcbcdf4bc9b7f6031ec119e89fd /src/lread.c | |
parent | d67f27bc83e8e1b2090ff810e3e41d927d96ceee (diff) | |
download | emacs-e93abe3da7f18b44aad0aa302f15f6777c7d1627.tar.gz |
(read1): Redo the previous change with checking
Vpurify_flag.
Diffstat (limited to 'src/lread.c')
-rw-r--r-- | src/lread.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/src/lread.c b/src/lread.c index 2df624d086f..6674f840686 100644 --- a/src/lread.c +++ b/src/lread.c @@ -2992,19 +2992,18 @@ read1 (readcharfun, pch, first_in_list) } } { -#if 0 - /* Fixme: The fullowing code is currently commented out - because it results in strange error in C-h f. For the - moment, I don't have a time to track down the - problem. -- Handa */ - Lisp_Object name = make_specified_string (read_buffer, -1, - p - read_buffer, - multibyte); - Lisp_Object result = (uninterned_symbol ? Fmake_symbol (name) - : Fintern (name, Qnil)); -#endif - Lisp_Object result = uninterned_symbol ? make_symbol (read_buffer) - : intern (read_buffer); + Lisp_Object name, result; + EMACS_INT nbytes = p - read_buffer; + EMACS_INT nchars + = (multibyte ? multibyte_chars_in_text (read_buffer, nbytes) + : nbytes); + + if (uninterned_symbol && ! NILP (Vpurify_flag)) + name = make_pure_string (read_buffer, nchars, nbytes, multibyte); + else + name = make_specified_string (read_buffer, nchars, nbytes,multibyte); + result = (uninterned_symbol ? Fmake_symbol (name) + : Fintern (name, Qnil)); if (EQ (Vread_with_symbol_positions, Qt) || EQ (Vread_with_symbol_positions, readcharfun)) |