git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Derrick Stolee <stolee@gmail.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: Git List <git@vger.kernel.org>
Subject: Re: Git Test Coverage Report (Nov 25)
Date: Thu, 28 Nov 2019 17:04:50 -0500	[thread overview]
Message-ID: <b9515bf6-81ec-3b24-8982-5248e36306fe@gmail.com> (raw)
In-Reply-To: <nycvar.QRO.7.76.6.1911272029050.31080@tvgsbejvaqbjf.bet>

On 11/27/2019 2:32 PM, Johannes Schindelin wrote:
> Hi Stolee,
> 
> On Wed, 27 Nov 2019, Derrick Stolee wrote:
> 
>> On 11/26/2019 3:46 PM, Johannes Schindelin wrote:
>>
>>> [...] the Windows build.
>>
>> Sorry that I have not set up a Windows build, but the Linux test-coverage
>> build already takes a long time so adding Windows would be complicated.
>> (Not to mention that merging the uncovered lines across two platforms would
>> be a huge challenge.)
>>
>> If anyone wants to consider such an effort, I'm willing to play along.
> 
> I fear it is even worse: once upon a time, I tried to set up a gcov run
> with mingw-w64-gcc, and it failed miserably (there was simply no output at
> all).
> 
> So I, for one, am completely comfortable with keeping the status quo for
> the time being.
> 
>>>> Johannes Schindelin	116d1fa6 vreportf(): avoid relying on stdio buffering
>>>> usage.c
>>>> 116d1fa6 16) fprintf(stderr, "BUG!!! too long a prefix '%s'\n", prefix);
>>>> 116d1fa6 17) abort();
>>>> 116d1fa6 22) *p = '\0'; /* vsnprintf() failed, clip at prefix */
>>>
>>> Those are defensive programming, so this is expected not to be covered.
>>
>> I wonder why we are not using BUG() here (for the fprintf and abort).
> 
> It's because `BUG()` calls `vreportf()`, and even if the _current_ version
> would bail out at some point, I would be uncomfortable calling `BUG()`
> from `vreportf()` and risk a (future-only) recursion ad infinitum.

That's a pretty good reason to not use BUG() here!

  reply	other threads:[~2019-11-28 22:05 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-25 15:33 Git Test Coverage Report (Nov 25) Derrick Stolee
2019-11-26 20:46 ` Johannes Schindelin
2019-11-27 14:33   ` Derrick Stolee
2019-11-27 19:32     ` Johannes Schindelin
2019-11-28 22:04       ` Derrick Stolee [this message]
2019-11-28 11:06   ` Phillip Wood

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b9515bf6-81ec-3b24-8982-5248e36306fe@gmail.com \
    --to=stolee@gmail.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).