diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-09-02 18:47:39 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-09-02 18:47:39 -0400 |
| commit | 61e482f6f36aee6f72392a6188f2ec5c858b88fd (patch) | |
| tree | bea4123fcc62dd834405ae89ce9fe260e90a0023 /builtins/types.h | |
| parent | f0f8f218703ebb4512b3cd3f9e06b86a7d9861b0 (diff) | |
Initial WIP first past
Diffstat (limited to 'builtins/types.h')
| -rw-r--r-- | builtins/types.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/builtins/types.h b/builtins/types.h index 70f8dc00..2647ef92 100644 --- a/builtins/types.h +++ b/builtins/types.h @@ -2,7 +2,6 @@ // Type information and methods for TypeInfos (i.e. runtime representations of types) -#include <gc/cord.h> #include <stdbool.h> #include <stdint.h> @@ -13,7 +12,7 @@ struct TypeInfo; typedef uint32_t (*hash_fn_t)(const void*, const struct TypeInfo*); typedef int32_t (*compare_fn_t)(const void*, const void*, const struct TypeInfo*); typedef bool (*equal_fn_t)(const void*, const void*, const struct TypeInfo*); -typedef CORD (*str_fn_t)(const void*, bool, const struct TypeInfo*); +typedef Text_t (*text_fn_t)(const void*, bool, const struct TypeInfo*); typedef struct TypeInfo { int64_t size, align; @@ -24,7 +23,7 @@ typedef struct TypeInfo { equal_fn_t equal; compare_fn_t compare; hash_fn_t hash; - str_fn_t as_text; + text_fn_t as_text; } CustomInfo; struct { const char *sigil; @@ -76,7 +75,7 @@ extern const TypeInfo $Void; extern const TypeInfo $Abort; #define Void_t void -CORD Type$as_text(const void *typeinfo, bool colorize, const TypeInfo *type); -CORD Func$as_text(const void *fn, bool colorize, const TypeInfo *type); +Text_t Type$as_text(const void *typeinfo, bool colorize, const TypeInfo *type); +Text_t Func$as_text(const void *fn, bool colorize, const TypeInfo *type); // vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 |
