<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Apr 7, 2017 at 4:15 AM, Cillian O'Donnell <span dir="ltr"><<a href="mailto:cpodonnell8@gmail.com" target="_blank">cpodonnell8@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Great! That looks like a cleaner, more standardized solution. I was just hacking away until the warnings stopped. So can I go ahead and #include <inttypes.h> or should I wait until <rtems/inttypes.h> is defined before doing any more? Does this work for printk() too?<br></div></div></blockquote><div><br></div><div>First the easy answer. printk() supports a subset of printf() formats. So</div><div>as long as it is a supported printf format, then yes. But I just looked for</div><div>printk() documentation and I don't see any. The code is in </div><div>cpukit/libcsupport/src/vprintk.c for a double check. It is supposed to</div><div>support everything required by any test.</div><div><br></div><div>If a file only uses C99 standard PRI constants, then use <inttypes.h></div><div><br></div><div>If a file needs the extra ones being collected into <rtems/inttypes.h>,</div><div>then it should include that.</div><div><br></div><div>No need to introduce an unneeded dependency.</div><div><br></div><div>Funny, how this simple set of warnings has rippled. It also makes me</div><div>want to file a ticket for printk() documentation and adding code style</div><div>rules about <inttypes.h>. </div><div><br></div><div>--joel</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div>Thanks Joel.<br></div>
<br>______________________________<wbr>_________________<br>
devel mailing list<br>
<a href="mailto:devel@rtems.org">devel@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/devel" rel="noreferrer" target="_blank">http://lists.rtems.org/<wbr>mailman/listinfo/devel</a><br></blockquote></div><br></div></div>