Cyclone Scheme  0.28.0

◆ make_utf8_string_with_len

#define make_utf8_string_with_len (   cs,
  s,
  length,
  num_code_points 
)
Value:
{ int len = length; \
cs.hdr.grayed = 0; \
cs.hdr.immutable = 0; \
cs.tag = string_tag; cs.len = len; \
cs.num_cp = num_code_points; \
cs.str = alloca(sizeof(char) * (len + 1)); \
memcpy(cs.str, s, len); \
cs.str[len] = '\0';}

Create a new string with the given length (so it does not need to be computed)

gc_color_red
#define gc_color_red
Definition: types.h:297
string_type::len
int len
Definition: types.h:937
string_type::str
char * str
Definition: types.h:938
gc_header_type_t::mark
unsigned char mark
Definition: types.h:268
string_type::hdr
gc_header_type hdr
Definition: types.h:934
string_type
The string type.
Definition: types.h:933
string_tag
@ string_tag
Definition: types.h:67