[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "as-is" rule

From: Samuel Bronson
Subject: Re: "as-is" rule
Date: Wed, 30 Nov 2011 13:44:09 -0500

On Wed, Nov 30, 2011 at 9:20 AM, Stefan Monnier
<address@hidden> wrote:
>> See bug #10164: I've been hit by code re-ordering under the "as-is" rule.
>> I asked before, but no one replied: is there a place where I can read
>> the description of conditions that _disallow_ such reordering?
> I think you've hit a bug in gcc in this case: "e1 || e2" should not
> evaluate e2 if e1 evaluates to non-0.  The as-is rule allows gcc to run
> any part of e2 (or any other code for that matter) at any time it feels
> like, but only if you can't tell the difference, and in this case we can
> definitely tell the difference.

Not to nitpick, but ... (oh, who am I kidding -- yes, to nitpick!)

... isn't that called the "as-if" rule?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]