https://issues.dlang.org/show_bug.cgi?id=23064

Basile-z <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #1 from Basile-z <[email protected]> ---
After a brief discussion on IRC it seems that C does not allow the conditional
expression to be a lvalue, hence it could not be an assignment RHS.

>From http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1548.pdf

---
 The first operand is evaluated; there is a sequence point between its
evaluation and the
evaluation of the second or third operand (whichever is evaluated). The second
operand
is evaluated only if the first compares unequal to 0; the third operand is
evaluated only if
the first compares equal to 0; the result is the value of the second or third
operand
(whichever is evaluated), converted to the type described below.110)

[...]

110) A conditional expression does not yield an lvalue
---

that would not affect ImportC then.

--

Reply via email to