Thread (25 messages) 25 messages, 5 authors, 2014-07-07

Re: [PATCH v2] declance: Fix 64-bit compilation warnings

From: Joe Perches <joe@perches.com>
Date: 2014-07-03 05:16:09

On Thu, 2014-07-03 at 05:51 +0100, Maciej W. Rozycki wrote:
quoted
The kernel vsprintf implementation doesn't prefix
pointers with 0x, so you can use 0x%p if you really
want that with a leading prefix, but you don't have
to use it.
 It does, when the `#' format modifier is used (go try yourself!).
I know it does, but it's incidental.

I phrased it badly though.
There's no code that uses it.

$ git grep "%#p" | wc -l
0

And I know that code pretty well thanks.
I think using 0x%p 
would be ugly; here it wouldn't really matter, but ordinarily allowing a 
format to produce `0x (null)' would be rather lame, so I don't want to 
spread examples someone might foolishly copy.
$ git grep "0x%p" | wc -l
1747

<shrug>  What's one more...

cheers, Joe
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help