diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-11-29 18:09:12 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-11-29 18:09:12 -0500 |
| commit | f66f8ad7119207b99f00ea2ea389550ee65db5b3 (patch) | |
| tree | 5b5a7c887b311e3de2f2cb293b1228598c5b9eb1 /stdlib/text.h | |
| parent | 4b5e4cd1f21582f5e5fa682ab4e4bff252963468 (diff) | |
Add serialization and deserialization
Diffstat (limited to 'stdlib/text.h')
| -rw-r--r-- | stdlib/text.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/stdlib/text.h b/stdlib/text.h index 04c867c5..b493f4ae 100644 --- a/stdlib/text.h +++ b/stdlib/text.h @@ -60,6 +60,8 @@ Text_t Text$join(Text_t glue, Array_t pieces); Text_t Text$repeat(Text_t text, Int_t count); int32_t Text$get_grapheme_fast(TextIter_t *state, int64_t index); uint32_t Text$get_main_grapheme_fast(TextIter_t *state, int64_t index); +void Text$serialize(const void *obj, FILE *out, Table_t *, const TypeInfo_t *); +void Text$deserialize(FILE *in, void *out, Array_t *, const TypeInfo_t *); MACROLIKE int32_t Text$get_grapheme(Text_t text, int64_t index) { @@ -75,6 +77,8 @@ extern const TypeInfo_t Text$info; .compare=Text$compare, \ .equal=Text$equal, \ .is_none=Text$is_none, \ + .serialize=Text$serialize, \ + .deserialize=Text$deserialize, \ }) // vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 |
