I need to be able to pass parameters to printf from another function. What I have so far works for some data types, but not character buffers, aka strings. Here is what I have that does not work. The SetDirection() are for setting the data direction of external hardware.
int xprintf (char *fmt, ...) { int rv; register int *varg = (int *)(&fmt); SetDirection(1); rv = printf(fmt, varg); SetDirection(0); return rv; }
When using part of a toolchain that does not claim compliance to the standard, what is your approach?
The approach was to doubt the documentation because I could not see any reason for a standard violation in this case. Keil doesn't claim full compliance to the standard, correct. But in my experience they do follow the standard where it's not an undue burden to do so. So I was surprised, and decided to look it up.