Re: [PATCH v2 3/5] *.h _INIT macros: don't specify fields equal to 0

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

 



Ævar Arnfjörð Bjarmason  <avarab@xxxxxxxxx> writes:

> -#define IPC_CLIENT_CONNECT_OPTIONS_INIT { \
> -	.wait_if_busy = 0, \
> -	.wait_if_not_found = 0, \
> -	.uds_disallow_chdir = 0, \
> -}
> +#define IPC_CLIENT_CONNECT_OPTIONS_INIT { 0 }

The original explicitly initializes the members using designated
init, and the loss somewhat feels like a temporary regression, but
as long as the new norm is

 - If there is *no* member that is initialized to non-zero value, we
   use { 0 }, and

 - Otherwise, we only explicitly initialize members to non-zero
   value using designated initializers

this conversion is perfectly fine.




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux