1 // cl_string concatenation.
13 #define MAYBE_INLINE inline
14 #include "cl_st_make0.cc"
16 const cl_string operator+ (const cl_string& str1, const cl_string& str2)
18 unsigned long len1 = strlen(str1);
19 unsigned long len2 = strlen(str2);
20 var cl_heap_string* str = cl_make_heap_string(len1+len2);
21 var char * ptr = &str->data[0];
23 var const char * ptr1 = asciz(str1);
24 for (var unsigned long count = len1; count > 0; count--)
28 var const char * ptr2 = asciz(str2);
29 for (var unsigned long count = len2; count > 0; count--)