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

Re: [PATCH] enums: remove trailing ',' after last item in enum

From
Ronnie Sahlberg <sahlberg@google.com>
Date
Jul 2, 2014, 20:08 UTC
Message-ID
<CAL=YDWmz+aQeDAukmH6mweX3q3Sn0g8XYzLxKKGgcQeO3BZNJw@mail.gmail.com>
In-Reply-To
<20140702195805.GD5816@google.com>
GCC can check/error for this with
--pedantic -Werror
On Wed, Jul 2, 2014 at 12:58 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 24 quoted lines
> Ronnie Sahlberg wrote:
>
>> Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
>> ---
>>  builtin/clean.c | 2 +-
>>  builtin/tag.c   | 2 +-
>>  pretty.c        | 2 +-
>>  3 files changed, 3 insertions(+), 3 deletions(-)
>
> Is there some gcc option or other tool that can automatically detect
> this kind of problem so the regress/fix cycle doesn't have to repeat
> too many times?
>
> Looks like v1.7.2-rc0~32^2~16 (2010-03-14) and v1.7.4.2~34 (2011-03-16)
> tried to fix this in the past.
>
> Using the test from v1.7.4.2~34 also finds enums with trailing comma
> in
>
>  grep.h
>  log-tree.c
>
> Thanks,
> Jonathan
Previous: Jonathan NiederNext: Junio C Hamano
Message 3 of 4 in “enums: remove trailing ',' after last item in enum”
  1. enums: remove trailing ',' after last item in enumRonnie Sahlberg, Jul 2, 2014
  2. Jonathan NiederJul 2, 2014
  3. Ronnie SahlbergJul 2, 2014
  4. Junio C HamanoJul 9, 2014

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.