Home - Search - Members
Full Version: What does adding a "u" to a hexadecimal number do?
Todor
Jun 27 2008, 12:18 AM
Hi, everyone! I'm new in this forum, so if my thread is in the wrong place, please move it.
I'm looking at a C source code for a C8051F124(8051 based), and I've found the following definition "#define ARP_OPERATION_REQ 0x01u". My question is, what does the "u" letter do with the constant value?

P.S. I suppose, that it have something to do with a little-endian - big-endian compatibility, but I'm not sure.

Thanks in advantage!
sashijoseph
Jun 28 2008, 5:37 AM
I think it forces the value to be an unsigned type...
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Rickey's World © 2003 - 2007