Add ArenaTemp to the compiler

This commit is contained in:
gingerBill
2023-01-12 00:47:20 +00:00
parent e9cfe698ba
commit 520ff731de
8 changed files with 107 additions and 12 deletions

View File

@@ -716,6 +716,8 @@ gb_internal LoadedFileError load_file_32(char const *fullpath, LoadedFile *memor
if (!copy_file_contents) {
#if defined(GB_SYSTEM_WINDOWS)
TEMPORARY_ALLOCATOR_GUARD();
isize w_len = 0;
wchar_t *w_str = gb__alloc_utf8_to_ucs2(temporary_allocator(), fullpath, &w_len);
if (w_str == nullptr) {
@@ -817,6 +819,8 @@ gb_internal LoadedFileError load_file_32(char const *fullpath, LoadedFile *memor
#define USE_DAMERAU_LEVENSHTEIN 1
gb_internal isize levenstein_distance_case_insensitive(String const &a, String const &b) {
TEMPORARY_ALLOCATOR_GUARD();
isize w = b.len+1;
isize h = a.len+1;
isize *matrix = gb_alloc_array(temporary_allocator(), isize, w*h);