Make the string type elements "immutable", akin to char const * in C

Allows for extra security and optimization benefits
This commit is contained in:
gingerBill
2019-12-01 14:10:59 +00:00
parent 7fbe0a6f23
commit 9db81498d8
25 changed files with 255 additions and 176 deletions
+2 -2
View File
@@ -493,8 +493,8 @@ String path_to_fullpath(gbAllocator a, String s) {
// Replace Windows style separators
for (isize i = 0; i < result.len; i++) {
if (result[i] == '\\') {
result[i] = '/';
if (result.text[i] == '\\') {
result.text[i] = '/';
}
}
}