aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndrea Corallo2019-12-07 10:24:13 +0100
committerAndrea Corallo2020-01-01 11:38:11 +0100
commite05253cb9bc4a35c7dedc3cbb2830e37d385a339 (patch)
tree75594e331c74fa00b17f87751e791835fc61a311 /src
parent60a81f44e49c77ef9143a665f94f89109002133d (diff)
downloademacs-e05253cb9bc4a35c7dedc3cbb2830e37d385a339.tar.gz
emacs-e05253cb9bc4a35c7dedc3cbb2830e37d385a339.zip
let intern_c_string works creating with non-pure strings
Diffstat (limited to 'src')
-rw-r--r--src/lread.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/lread.c b/src/lread.c
index bd7182c398f..f280dad97c0 100644
--- a/src/lread.c
+++ b/src/lread.c
@@ -4198,10 +4198,14 @@ intern_c_string_1 (const char *str, ptrdiff_t len)
4198 4198
4199 if (!SYMBOLP (tem)) 4199 if (!SYMBOLP (tem))
4200 { 4200 {
4201 /* Creating a non-pure string from a string literal not implemented yet. 4201 Lisp_Object string;
4202 We could just use make_string here and live with the extra copy. */ 4202
4203 eassert (!NILP (Vpurify_flag)); 4203 if (NILP (Vpurify_flag))
4204 tem = intern_driver (make_pure_c_string (str, len), obarray, tem); 4204 string = make_string (str, len);
4205 else
4206 string = make_pure_c_string (str, len);
4207
4208 tem = intern_driver (string, obarray, tem);
4205 } 4209 }
4206 return tem; 4210 return tem;
4207} 4211}