Re: using sizeof operator

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jan 22, 2012 at 11:58:30PM +0530, Sukrit Sangwan wrote:
> also i want to ask why not use simply 8 instead of sizeof(u8).

That would be 1 most of the time. sizeof returns the size in bytes
(according to the C reference manual in K&R's book).

Apart from that, sizeof(u8) is more explicit about the intention.

HTH,
	Jonathan Neuschäfer

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux