iodine/printd.ih library provides printd, a C-style formatted output function that writes to standard output and appends a newline.
Print a value
Pass a format string and values, such as
printd("count: %d", count).One call, one line
printd appends a newline after each call.Import printd
Importprintd from iodine. Choose whether to expose the function or retain an explicit namespace qualifier.
- Expose printd
- Use the namespace
After
expose printd, call the function directly:Supported format specifiers
The library handles common C-style format tokens:
Pass values after the format string, as you would with C’s
printf. For example:
write system call. Its sys_write assembly function is defined inside printd.ih.