Set immutable flag

This commit is contained in:
Justin Ethier 2019-05-01 17:41:47 -04:00
parent 3f6e9655bd
commit f0b84ce122
2 changed files with 3 additions and 0 deletions

View file

@ -1020,6 +1020,7 @@
&heap_grown);
((string_type *) s)->hdr.mark = ((gc_thread_data *)data)->gc_alloc_color;
((string_type *) s)->hdr.grayed = 0;
((string_type *) s)->hdr.immutable = 0;
((string_type *) s)->tag = string_tag;
((string_type *) s)->len = len;
((string_type *) s)->num_cp = num_cp;
@ -1028,6 +1029,7 @@
s = alloca(sizeof(string_type));
((string_type *)s)->hdr.mark = gc_color_red;
((string_type *)s)->hdr.grayed = 0;
((string_type *)s)->hdr.immutable = 0;
((string_type *)s)->tag = string_tag;
((string_type *)s)->len = len;
((string_type *)s)->num_cp = num_cp;

View file

@ -28,6 +28,7 @@
memcpy(ps, &s, sizeof(string_type));
((list)pl)->hdr.mark = gc_color_red;
((list)pl)->hdr.grayed = 0;
((list)pl)->hdr.immutable = 0;
((list)pl)->tag = pair_tag;
((list)pl)->pair_car = ps;
((list)pl)->pair_cdr = lis;