Re: [PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-09 Thread Christian Couder
From: Junio C Hamano gits...@pobox.com Christian Couder chrisc...@tuxfamily.org writes: +enum action_where { WHERE_AFTER, WHERE_BEFORE }; +enum action_if_exist { EXIST_ADD_IF_DIFFERENT, EXIST_ADD_IF_DIFFERENT_NEIGHBOR, + EXIST_ADD, EXIST_OVERWRITE, EXIST_DO_NOTHING };

Re: [PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-09 Thread Christian Couder
From: Junio C Hamano gits...@pobox.com Christian Couder chrisc...@tuxfamily.org writes: +enum action_if_exist if_exist; +enum action_if_missing if_missing; Probably if_exists is more gramatically correct. if (x-if_exists) { ... do this ... } would

Re: [PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-09 Thread Eric Sunshine
On Sun, Feb 9, 2014 at 8:48 AM, Christian Couder chrisc...@tuxfamily.org wrote: From: Junio C Hamano gits...@pobox.com Christian Couder chrisc...@tuxfamily.org writes: +static inline int same_trailer(struct trailer_item *a, struct trailer_item *b, int alnum_len) +{ +return

[PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-06 Thread Christian Couder
We will use a doubly linked list to store all information about trailers and their configuration. This way we can easily remove or add trailers to or from trailer lists while traversing the lists in either direction. Signed-off-by: Christian Couder chrisc...@tuxfamily.org --- Makefile | 1 +

Re: [PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-06 Thread Junio C Hamano
Christian Couder chrisc...@tuxfamily.org writes: We will use a doubly linked list to store all information about trailers and their configuration. This way we can easily remove or add trailers to or from trailer lists while traversing the lists in either direction. Signed-off-by: Christian

Re: [PATCH v5 01/14] Add data structures and basic functions for commit trailers

2014-02-06 Thread Junio C Hamano
Christian Couder chrisc...@tuxfamily.org writes: + enum action_if_exist if_exist; + enum action_if_missing if_missing; Probably if_exists is more gramatically correct. if (x-if_exists) { ... do this ... } would read well, but not x-if_exist.