From 3c379fbfb2b7301cd5c4f5371a9f0b96a1369b60 Mon Sep 17 00:00:00 2001 From: Tyge Løvset Date: Fri, 4 Mar 2022 13:18:35 +0100 Subject: Updated printf formatting to portable code. This was also to use http://winlibs.com gcc+clang with ucrt runtime-libs without warnings. --- examples/priority.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'examples/priority.c') diff --git a/examples/priority.c b/examples/priority.c index 184cad9f..1767dba8 100644 --- a/examples/priority.c +++ b/examples/priority.c @@ -15,7 +15,7 @@ int main() { c_auto (cpque_i, heap) { // Push ten million random numbers to priority queue - printf("Push %zu numbers\n", N); + printf("Push %" PRIuMAX " numbers\n", N); c_forrange (N) cpque_i_push(&heap, stc64_uniform(&rng, &dist)); @@ -27,7 +27,7 @@ int main() { puts("Extract the hundred smallest."); c_forrange (100) { - printf("%zd ", *cpque_i_top(&heap)); + printf("%" PRIdMAX " ", *cpque_i_top(&heap)); cpque_i_pop(&heap); } } -- cgit v1.2.3