From 3c52a756339a2d96824d21a7d3ad5de7fc1085a0 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Thu, 27 Mar 2025 17:26:51 -0400 Subject: Deprecate custom printf specifiers in favor of print() function that uses _Generic() to generically convert any value to a string or print as a string. --- src/stdlib/text.h | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/stdlib/text.h') diff --git a/src/stdlib/text.h b/src/stdlib/text.h index 0a44f4e4..e5c6a14f 100644 --- a/src/stdlib/text.h +++ b/src/stdlib/text.h @@ -4,7 +4,6 @@ // Raku's string representation and libunistr #include -#include #include #include "datatypes.h" @@ -25,12 +24,9 @@ typedef struct { #define NEW_TEXT_ITER_STATE(t) (TextIter_t){.stack={{t, 0}}, .stack_index=0} -int printf_text(FILE *stream, const struct printf_info *info, const void *const args[]); -int printf_text_size(const struct printf_info *info, size_t n, int argtypes[n], int sizes[n]); - #define Text(str) ((Text_t){.length=sizeof(str)-1, .tag=TEXT_ASCII, .ascii="" str}) -int Text$print(FILE *stream, Text_t t); +//int Text$print(FILE *stream, Text_t t); Text_t Text$_concat(int n, Text_t items[n]); #define Text$concat(...) Text$_concat(sizeof((Text_t[]){__VA_ARGS__})/sizeof(Text_t), (Text_t[]){__VA_ARGS__}) #define Texts(...) Text$concat(__VA_ARGS__) -- cgit v1.2.3