diff options
| author | realtradam <[email protected]> | 2023-04-12 19:18:59 -0400 |
|---|---|---|
| committer | realtradam <[email protected]> | 2023-04-12 19:18:59 -0400 |
| commit | f250a4090cf4d535a163388fb5faea5ff1ce48e4 (patch) | |
| tree | abccaee35e10fb05ec06f621ea14adf598ff53cc /include/rodeo_types.h | |
| parent | 231185997aef8b675033cf1a32db79e140bcef06 (diff) | |
| download | RodeoKit-f250a4090cf4d535a163388fb5faea5ff1ce48e4.tar.gz RodeoKit-f250a4090cf4d535a163388fb5faea5ff1ce48e4.zip | |
remove string wrapper, use STC directly instead
Diffstat (limited to 'include/rodeo_types.h')
| -rw-r--r-- | include/rodeo_types.h | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/include/rodeo_types.h b/include/rodeo_types.h index a75da40..4ed7767 100644 --- a/include/rodeo_types.h +++ b/include/rodeo_types.h @@ -1,5 +1,8 @@ #pragma once +// external +#include "stc/cstr.h" + // system #include <stdbool.h> #include <stdint.h> @@ -86,18 +89,6 @@ typedef struct rodeo_frameBuffer_2d_t; */ -/// --- String --- - -// taken from STC library -// must match their layout exactly as it will be cast to it. -// (TODO should write test cases for the string funcs) -typedef char rodeo_string_value_t; -typedef struct { rodeo_string_value_t* data; intptr_t size, cap; } rodeo_string_buffer_t; -typedef union { - struct { rodeo_string_value_t data[sizeof(rodeo_string_buffer_t) - 1]; unsigned char size; } sml; - struct { rodeo_string_value_t* data; size_t size, ncap; } lon; -} rodeo_string_t; - /// --- Log --- typedef @@ -111,7 +102,7 @@ rodeo_logLevel_t; typedef void -(*rodeo_log_function)(rodeo_string_t text); +(*rodeo_log_function)(cstr text); typedef union |
