Re: [PATCH 1/4] submodule: amend extra line feed between callback struct and macro

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

 



Hi Shourya,

"amend" sounds a little awkward to describe what the patch does. Maybe
"submodule: remove extra empty lines"?

On Fri, 3 Jul 2020, Shourya Shukla wrote:

> All subcommands of 'git submodule' using a callback mechanism had
> absence of an extra linefeed between their callback structs and
> macros. Subcommands 'init', 'status' and 'sync' did not follow suit.
> Amend the extra line feed.

Maybe a native reader can suggest something that flows a bit easier? I am
not a native English speaker, but I'd prefer something along those lines:

	Many `submodule--helper` subcommands follow the convention a
	struct defines their callback data, and the declaration of said
	struct is followed immediately by a macro to use in static
	initializers, without any separating empty line.

	Let's align the `init`, `status` and `sync` subcommands with that
	convention.

The patch obviously does what the commit message promises.

Ciao,
Dscho

> Mentored-by: Christian Couder <chriscool@xxxxxxxxxxxxx>
> Mentored-by: Kaartic Sivaraam <kaartic.sivaraam@xxxxxxxxx>
> Signed-off-by: Shourya Shukla <shouryashukla.oo@xxxxxxxxx>
> ---
>  builtin/submodule--helper.c | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/builtin/submodule--helper.c b/builtin/submodule--helper.c
> index 59c1e1217c..eea3932c40 100644
> --- a/builtin/submodule--helper.c
> +++ b/builtin/submodule--helper.c
> @@ -612,7 +612,6 @@ struct init_cb {
>  	const char *prefix;
>  	unsigned int flags;
>  };
> -
>  #define INIT_CB_INIT { NULL, 0 }
>
>  static void init_submodule(const char *path, const char *prefix,
> @@ -742,7 +741,6 @@ struct status_cb {
>  	const char *prefix;
>  	unsigned int flags;
>  };
> -
>  #define STATUS_CB_INIT { NULL, 0 }
>
>  static void print_status(unsigned int flags, char state, const char *path,
> @@ -933,7 +931,6 @@ struct sync_cb {
>  	const char *prefix;
>  	unsigned int flags;
>  };
> -
>  #define SYNC_CB_INIT { NULL, 0 }
>
>  static void sync_submodule(const char *path, const char *prefix,
> --
> 2.27.0
>
>




[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