[cfe-dev] Confusion on interpretations

Devchandra L Meetei dlmeetei at gmail.com
Thu May 16 11:49:19 PDT 2013


Thought that clang is interpreting it wrong. Sorry for the noise


On Fri, May 17, 2013 at 12:18 AM, Richard Smith <richard at metafoo.co.uk>wrote:

> This is not a forum for teaching C++. Maybe try asking on stackoverflow?
>
> On Thu, May 16, 2013 at 11:18 AM, Devchandra L Meetei <dlmeetei at gmail.com>wrote:
>
>> But parentheses should have highest priority ? even before n>= 4
>>
>>
>> On Thu, May 16, 2013 at 11:36 PM, Jeffrey Walton <noloader at gmail.com>wrote:
>>
>>> On Thu, May 16, 2013 at 1:51 PM, Devchandra L Meetei <dlmeetei at gmail.com>
>>> wrote:
>>> >
>>> > SUppose if We have
>>> > t = 128;
>>> > n = 3;
>>> > while ( n >= 4 && ((t = 7) & 0x80) == 0 )
>>> >
>>> > why t is 128 after the loop. As we learnt that parentheses has highest
>>> > priority.
>>> > Won't in this case t be 7. why the value is still 128?
>>> n >= 4 is false, so evaluation stops.
>>>
>>
>>
>>
>> --
>> Warm Regards
>> --Dev
>> OpenPegasus Developer/Committer
>>
>> (\__/)
>> (='.'=) This is Bunny. Copy and paste bunny
>> (")_(") to help him gain world domination.
>>
>> _______________________________________________
>> cfe-dev mailing list
>> cfe-dev at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
>>
>>
>


-- 
Warm Regards
--Dev
OpenPegasus Developer/Committer

(\__/)
(='.'=) This is Bunny. Copy and paste bunny
(")_(") to help him gain world domination.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130517/9e86418e/attachment.html>


More information about the cfe-dev mailing list