From 5ec606e5dfdbaebe22717d094b58ee7f365ffd9c Mon Sep 17 00:00:00 2001 From: Tyge Løvset Date: Sun, 6 Nov 2022 15:52:16 +0100 Subject: Added c_autodrop() macro, and removed c_autobuf() which wasn't that useful (and was undocumented). --- examples/bits2.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'examples/bits2.c') diff --git a/examples/bits2.c b/examples/bits2.c index 95eb8b83..59e0b337 100644 --- a/examples/bits2.c +++ b/examples/bits2.c @@ -11,12 +11,11 @@ int main() printf("size %" c_ZU "\n", Bits_size(&s1)); char buf[256]; - Bits_to_str(&s1, buf, 0, -1); + Bits_to_str(&s1, buf, 0, 256); printf("buf: %s: count=%" c_ZU "\n", buf, Bits_count(&s1)); Bits_reset(&s1, 8); - c_autobuf (str, char, Bits_size(&s1) + 1) - printf(" s1: %s\n", Bits_to_str(&s1, str, 0, -1)); + printf(" s1: %s\n", Bits_to_str(&s1, buf, 0, 256)); Bits s2 = Bits_clone(s1); -- cgit v1.2.3