Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: TIL: C++17 sequences assignment the wrong way.

35 views
Skip to first unread message

Tim Rentsch

unread,
Jul 30, 2019, 10:22:59 AM7/30/19
to
r...@zedat.fu-berlin.de (Stefan Ram) writes:

> Newsgroups: comp.lang.lisp,comp.lang.c++
>
> Stefan Monnier <mon...@iro.umontreal.ca> writes:
>
>> Do you happen to have a reference to this part of the spec?
>
> In the most recent draft, n4800, it's 7.6.18p1:
>
> The right operand is sequenced before the left operand.
>
> . The assignment stores the value of the right operand
> into the object indicated by the left operand, so the
> operations involved are:
>
> First, obtain the value of the right operand,
> then, store this value into the left operand.
>
> Therefore some kind of right-to-left sequencing is part
> of the semantics the assignment already always had, in
> any language.

This summary sentence is utter nonsense.

Keith Thompson

unread,
Jul 30, 2019, 4:09:03 PM7/30/19
to
What does the phrase "This summary sentence" refer to?

--
Keith Thompson (The_Other_Keith) ks...@mib.org <http://www.ghoti.net/~kst>
Will write code for food.
void Void(void) { Void(); } /* The recursive call of the void */

Tim Rentsch

unread,
Aug 9, 2019, 1:36:59 PM8/9/19
to
Keith Thompson <ks...@mib.org> writes:

> Tim Rentsch <tr.1...@z991.linuxsc.com> writes:
>
>> r...@zedat.fu-berlin.de (Stefan Ram) writes:
>>
>>> Newsgroups: comp.lang.lisp,comp.lang.c++
>>>
>>> Stefan Monnier <mon...@iro.umontreal.ca> writes:
>>>
>>>> Do you happen to have a reference to this part of the spec?
>>>
>>> In the most recent draft, n4800, it's 7.6.18p1:
>>>
>>> The right operand is sequenced before the left operand.
>>>
>>> . The assignment stores the value of the right operand
>>> into the object indicated by the left operand, so the
>>> operations involved are:
>>>
>>> First, obtain the value of the right operand,
>>> then, store this value into the left operand.
>>>
>>> Therefore some kind of right-to-left sequencing is part
>>> of the semantics the assignment already always had, in
>>> any language.
>>
>> This summary sentence is utter nonsense.
>
> What does the phrase "This summary sentence" refer to?

The sentence that starts "Therefore some kind of ...".
0 new messages