Re: Why use "." in the struct in this way?

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

 



On 30/07/13 00:56, lx wrote:
> hi all:
>        why use the struct in this way by "."
> 
> for example, *.owner* instead of *owner* , why? 

It's utilising a feature known as designated initialisers. Essentially,
using this technique, struct members may be initialised out of order
from the way the struct is defined.

cf.
http://en.wikipedia.org/wiki/Struct_(C_programming_language)#Struct_initialization

Cheers,

Dave

_______________________________________________
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