mirror of
https://github.com/Ed94/WATL_Exercise.git
synced 2025-08-06 07:12:42 -07:00
c file trailing whitespace remvoval
This commit is contained in:
@@ -302,7 +302,7 @@ typedef def_struct(FArena) {
|
|||||||
SSIZE capacity;
|
SSIZE capacity;
|
||||||
SSIZE used;
|
SSIZE used;
|
||||||
};
|
};
|
||||||
FArena farena_make (Slice_Byte byte);
|
FArena farena_make (Slice_Byte mem);
|
||||||
void farena_init (FArena* arena, Slice_Byte byte);
|
void farena_init (FArena* arena, Slice_Byte byte);
|
||||||
Slice_Byte farena__push (FArena* arena, SSIZE amount, SSIZE type_width, Opts_farena* opts);
|
Slice_Byte farena__push (FArena* arena, SSIZE amount, SSIZE type_width, Opts_farena* opts);
|
||||||
void farena_reset (FArena* arena);
|
void farena_reset (FArena* arena);
|
||||||
@@ -446,10 +446,10 @@ SSIZE kt1l__populate_slice_a2(KT1L_Byte* kt, AllocatorInfo backing, KT1L_Meta m,
|
|||||||
cast(KT1L_Byte*, kt), \
|
cast(KT1L_Byte*, kt), \
|
||||||
ainfo, \
|
ainfo, \
|
||||||
(KT1L_Meta){ \
|
(KT1L_Meta){ \
|
||||||
.slot_size = size_of(KT1L_Slot_Str8), \
|
.slot_size = size_of(KT1L_Slot_Str8), \
|
||||||
.kt_value_offset = offset_of(tmpl(KT1L_Slot,type), value), \
|
.kt_value_offset = offset_of(tmpl(KT1L_Slot,type), value), \
|
||||||
.type_width = size_of(type), \
|
.type_width = size_of(type), \
|
||||||
.type_name = lit(stringify(type)) \
|
.type_name = lit(stringify(type)) \
|
||||||
}, \
|
}, \
|
||||||
slice_byte(values), (values).len \
|
slice_byte(values), (values).len \
|
||||||
)
|
)
|
||||||
@@ -473,7 +473,6 @@ def_struct(tmpl(KT1CX,type)) { \
|
|||||||
tmpl(Slice_KT1CX_Cell,type) cell_pool; \
|
tmpl(Slice_KT1CX_Cell,type) cell_pool; \
|
||||||
tmpl(Slice_KT1CX_Cell,type) table; \
|
tmpl(Slice_KT1CX_Cell,type) table; \
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef def_struct(KT1CX_Byte_Slot) {
|
typedef def_struct(KT1CX_Byte_Slot) {
|
||||||
U64 key;
|
U64 key;
|
||||||
B32 occupied;
|
B32 occupied;
|
||||||
@@ -1031,7 +1030,6 @@ void os_init(void) {
|
|||||||
OS_SystemInfo* info = & os__windows_info.system_info;
|
OS_SystemInfo* info = & os__windows_info.system_info;
|
||||||
info->target_page_size = (SSIZE)GetLargePageMinimum();
|
info->target_page_size = (SSIZE)GetLargePageMinimum();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(Ed): Large pages disabled for now... (not failing gracefully)
|
// TODO(Ed): Large pages disabled for now... (not failing gracefully)
|
||||||
inline Byte* os__vmem_reserve(SSIZE size, Opts_vmem* opts) {
|
inline Byte* os__vmem_reserve(SSIZE size, Opts_vmem* opts) {
|
||||||
assert(opts != nullptr);
|
assert(opts != nullptr);
|
||||||
@@ -1766,7 +1764,6 @@ Str8 cache_str8(Str8Cache* cache, Str8 str) {
|
|||||||
Str8* result = str8cache_set(cache->kt, key, str, cache->str_reserve, cache->cell_reserve);
|
Str8* result = str8cache_set(cache->kt, key, str, cache->str_reserve, cache->cell_reserve);
|
||||||
return * result;
|
return * result;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline
|
inline
|
||||||
void str8gen_init(Str8Gen* gen, AllocatorInfo backing) {
|
void str8gen_init(Str8Gen* gen, AllocatorInfo backing) {
|
||||||
assert(gen != nullptr);
|
assert(gen != nullptr);
|
||||||
@@ -1777,7 +1774,6 @@ void str8gen_init(Str8Gen* gen, AllocatorInfo backing) {
|
|||||||
gen->cap = kilo(4);
|
gen->cap = kilo(4);
|
||||||
}
|
}
|
||||||
inline Str8Gen str8gen_make(AllocatorInfo backing) { Str8Gen gen; str8gen_init(& gen, backing); return gen; }
|
inline Str8Gen str8gen_make(AllocatorInfo backing) { Str8Gen gen; str8gen_init(& gen, backing); return gen; }
|
||||||
|
|
||||||
inline
|
inline
|
||||||
void str8gen_append_str8(Str8Gen* gen, Str8 str){
|
void str8gen_append_str8(Str8Gen* gen, Str8 str){
|
||||||
Slice_Byte result = mem_grow(gen->backing, str8gen_slice_byte(* gen), str.len + gen->len);
|
Slice_Byte result = mem_grow(gen->backing, str8gen_slice_byte(* gen), str.len + gen->len);
|
||||||
|
Reference in New Issue
Block a user