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

Re: [PATCH v8 1/5] dir_iterator: add tests for dir_iterator API

From
Stefan Beller <sbeller@google.com>
Date
Apr 13, 2017, 00:42 UTC
Message-ID
<CAGZ79kaH0ihJ-zFX5zdK-av0Aqxi1ebCEqj5smb2Zu9pKRG8oA@mail.gmail.com>
In-Reply-To
<1491442767-54068-2-git-send-email-bnmvco@gmail.com>
On Wed, Apr 5, 2017 at 6:39 PM, Daniel Ferreira <bnmvco@gmail.com> wrote:
> +int cmd_main(int argc, const char **argv) {
Style (minor nit, in case resend is needed):

We only put the { brace on the same line for statements (if, for, while, switch), not for function declarations.

I tried to find a good rationale for it, this is the most sufficient I could find https://www.kernel.org/doc/Documentation/process/coding-style.rst (section 3):

    Heretic people all over the world have claimed that this inconsistency
    is ...  well ...  inconsistent, but all right-thinking people know that
    (a) K&R are **right** and (b) K&R are right.  Besides, functions are
    special anyway (you can't nest them in C).
Previous: Daniel FerreiraNext: Daniel Ferreira
Message 3 of 11 in “[GSoC] remove_subtree(): reimplement using iterators”
  1. 0/5 [GSoC] remove_subtree(): reimplement using iteratorsDaniel Ferreira, Apr 6, 2017
  2. 1/5 dir_iterator: add tests for dir_iterator APIDaniel Ferreira, Apr 6, 2017
  3. Stefan BellerApr 13, 2017
  4. 2/5 remove_subtree(): test removing nested directoriesDaniel Ferreira, Apr 6, 2017
  5. 4/5 dir_iterator: refactor state machine modelDaniel Ferreira, Apr 6, 2017
  6. Michael HaggertyApr 17, 2017
  7. 3/5 dir_iterator: add helpers to dir_iterator_advanceDaniel Ferreira, Apr 6, 2017
  8. 5/5 remove_subtree(): reimplement using iteratorsDaniel Ferreira, Apr 6, 2017
  9. Daniel Ferreira (theiostream)Apr 13, 2017
  10. Stefan BellerApr 13, 2017
  11. Michael HaggertyApr 17, 2017

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.