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

Re: [PATCH v2] Detailed diagnosis when parsing an object name fails.

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 7, 2009, 00:30 UTC
Message-ID
<7vtyw3bp7r.fsf@alter.siamese.dyndns.org>
In-Reply-To
<vpqhbs4dkjr.fsf@bauges.imag.fr>
Matthieu Moy <Matthieu.Moy@grenoble-inp.fr> writes:
Show 6 quoted lines
>>> +extern int get_sha1_with_mode_1(const char *str, unsigned char *sha1, unsigned *mode, int fatal, const char *prefix);
>>
>> Do I understand correctly that "fatal" here is the same as "!gently"
>> elsewhere in the API?
>
> It seems it is. I renamed it.

This was a pure question, not a suggestion to change it (we do name a function do_foo_gently() when there is do_foo() that does the same but reports errors more noisily, though). I found the name "fatal" a bit confusing as I at first couldn't tell if the caller was telling the function that it already detected a "fatal" error (and telling the function to report the fatalness) and didn't realize that the caller is instead saying "if you find an error, treat it as a fatal one" until I read it again.

I am Ok with the new "gently" name with the negative semantics as well (I see no need to change it back to "error_is_fatal").

Thanks.
Previous: Matthieu MoyNext: Junio C Hamano
Message 5 of 9 in “Detailed diagnosis when parsing an object name fails.”
  1. Detailed diagnosis when parsing an object name fails.y@imag.fr, Dec 2, 2009
  2. Junio C HamanoDec 3, 2009
  3. Matthieu MoyDec 6, 2009
  4. Detailed diagnosis when parsing an object name fails.Matthieu Moy, Dec 6, 2009
  5. Junio C HamanoDec 7, 2009
  6. Junio C HamanoDec 7, 2009
  7. Matthieu MoyDec 7, 2009
  8. Detailed diagnosis when parsing an object name fails.Matthieu Moy, Dec 7, 2009
  9. Sverre RabbelierFeb 15, 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.