I was wondering what is the difference between uint32_t
and uint32
, and when I looked in the header files it had this:
types.h: /** @brief 32-bit unsigned integer. */ typedef unsigned int uint32; stdint.h: typedef unsigned uint32_t;
This only leads to more questions: What is the difference between
unsigned varName;
and
unsigned int varName;
?
I am using MinGW.
The INTEGER data type stores whole numbers that range from -2,147,483,647 to 2,147,483,647 for 9 or 10 digits of precision. The number 2,147,483,648 is a reserved value and cannot be used. The INTEGER value is stored as a signed binary integer and is typically used to store counts, quantities, and so on.
4 Types of Data: Nominal, Ordinal, Discrete, Continuous.
unsigned
and unsigned int
are synonymous, much like unsigned short [int]
and unsigned long [int]
.
uint32_t
is a type that's (optionally) defined by the C standard. uint32
is just a name you made up, although it happens to be defined as the same thing.
There is no difference.
unsigned int = uint32 = uint32_t = unsigned
in your case and unsigned int = unsigned
always
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With