Re: Proposal: Replace NS_ASSERTION with MOZ_ASSERT and then remove it.

2019-10-30 Thread Bobby Holley
On Wed, Oct 30, 2019 at 8:47 AM Nathan Froyd  wrote:

> On Wed, Oct 30, 2019 at 11:36 AM Tom Ritter  wrote:
> >
> > I will claim that the most common behavior of developers is to leave
> > XPCOM_DEBUG_BREAK alone and not set it to any particular value. I bet
> most
> > people haven't even heard of this or know what it does.
> >
> > With that env var unset, in Debug mode, NS_ASSERTION will print to stderr
> > and otherwise do nothing. In non-Debug mode, it will just do nothing.
> >
> > Is that the best behavior for this? Should perhaps (most of) these
> claimed
> > assertions really be MOZ_ASSERT? Hence this proposal.
>
> You may be interested in
> https://bugzilla.mozilla.org/show_bug.cgi?id=1457813#c5, the links
> therein, and the following bug comments for why we have resisted a
> wholesale transition.
>

And because the discussion there references roc's arguments but doesn't
link to them, here they are:
https://robert.ocallahan.org/2011/12/case-for-non-fatal-assertions.html


>
> -Nathan
> ___
> dev-platform mailing list
> dev-platform@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-platform
>
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform


Re: Proposal: Replace NS_ASSERTION with MOZ_ASSERT and then remove it.

2019-10-30 Thread Nathan Froyd
On Wed, Oct 30, 2019 at 11:36 AM Tom Ritter  wrote:
>
> I will claim that the most common behavior of developers is to leave
> XPCOM_DEBUG_BREAK alone and not set it to any particular value. I bet most
> people haven't even heard of this or know what it does.
>
> With that env var unset, in Debug mode, NS_ASSERTION will print to stderr
> and otherwise do nothing. In non-Debug mode, it will just do nothing.
>
> Is that the best behavior for this? Should perhaps (most of) these claimed
> assertions really be MOZ_ASSERT? Hence this proposal.

You may be interested in
https://bugzilla.mozilla.org/show_bug.cgi?id=1457813#c5, the links
therein, and the following bug comments for why we have resisted a
wholesale transition.

-Nathan
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform