Basic call expression and fix to assignment count checking

This commit is contained in:
gingerBill
2016-08-03 22:27:36 +01:00
parent 0e92166d44
commit 19aea1f198
11 changed files with 332 additions and 226 deletions
+9 -8
View File
@@ -6352,16 +6352,17 @@ gb_inline void gb_string_clear(gbString str) { gb__set_string_length(str, 0); st
gb_inline gbString gb_string_append(gbString str, gbString const other) { return gb_string_append_length(str, other, gb_string_length(other)); }
gbString gb_string_append_length(gbString str, void const *other, isize other_len) {
isize curr_len = gb_string_length(str);
if (other_len > 0) {
isize curr_len = gb_string_length(str);
str = gb_string_make_space_for(str, other_len);
if (str == NULL)
return NULL;
gb_memcopy(str + curr_len, other, other_len);
str[curr_len + other_len] = '\0';
gb__set_string_length(str, curr_len + other_len);
str = gb_string_make_space_for(str, other_len);
if (str == NULL)
return NULL;
gb_memcopy(str + curr_len, other, other_len);
str[curr_len + other_len] = '\0';
gb__set_string_length(str, curr_len + other_len);
}
return str;
}