We are using C89 on an embedded platform. I attempted to print out a size_t
, but it did not work:
#include <stdio.h>
int main(void) {
size_t n = 123;
printf("%zu\n",n);
return 0;
}
Instead of 123
, I got zu
.
Other specifiers work correctly.
If size_t
exists shouldn't zu
also be available in printf
?
Is this something I should contact my library vendor about, or is a library implementation allowed to exclude it?
z
prefix was added in C99 I believe. – Ferdelance