maintain explicit casts in cstring -> string paths

This commit is contained in:
Ryan Fleury
2024-10-21 08:50:39 -07:00
parent dbcecd99af
commit 52245a8e5a
+4 -4
View File
@@ -215,8 +215,8 @@ str32_cstring(U32 *c){
internal String8
str8_cstring_capped(void *cstr, void *cap)
{
char *ptr = cstr;
char *opl = cap;
char *ptr = (char *)cstr;
char *opl = (char *)cap;
for (;ptr < opl && *ptr != 0; ptr += 1);
U64 size = (U64)(ptr - (char *)cstr);
String8 result = str8((U8*)cstr, size);
@@ -226,8 +226,8 @@ str8_cstring_capped(void *cstr, void *cap)
internal String16
str16_cstring_capped(void *cstr, void *cap)
{
U16 *ptr = cstr;
U16 *opl = cap;
U16 *ptr = (U16 *)cstr;
U16 *opl = (U16 *)cap;
for (;ptr < opl && *ptr != 0; ptr += 1);
U64 size = (U64)(ptr - (U16 *)cstr);
String16 result = str16(cstr, size);