git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] Convert the users of for_each_string_list to for_each_string_list_item macro

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 6, 2010, 02:35 UTC
Message-ID
<7v4ogd8hh5.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20100703124154.GB5511@blimp.localdomain>
Alex Riesen <raa.lkml@gmail.com> writes:
Show 10 quoted lines
> The rule for selecting the candidates for conversion is: if the callback
> function returns only 0 (the condition for for_each_string_list to exit
> early), than it can be safely converted to the macro.
>
> A notable exception are the callers in builtin/remote.c. If converted, the
> readability in the file will suffer greately. Besides, the code is not very
> performance critical (at the moment, at least): it does output formatting of
> the list of remotes.
>
> Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Both patches look very sane.  Thanks.
Previous: Alex Riesen
Message 5 of 5 in “Add a string_list_foreach macro”
  1. 1/2 Add a string_list_foreach macroAlex Riesen, Jun 29, 2010
  2. 1/2 Add a string_list_foreach macroAlex Riesen, Jul 2, 2010
  3. 1/2 Add a for_each_string_list_item macroAlex Riesen, Jul 3, 2010
  4. 2/2 Convert the users of for_each_string_list to for_each_string_list_item macroAlex Riesen, Jul 3, 2010
  5. Junio C HamanoJul 6, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.