Title
Bit-field in conditional operator with throw operand
Status
cd4
Section
7.6.16 [expr.cond]
Submitter
Richard Smith

Created on 2014-01-25.00:00:00 last changed 94 months ago

Messages

Date: 2014-11-15.00:00:00

[Moved to DR at the November, 2014 meeting.]

Date: 2014-02-15.00:00:00

Proposed resolution (February, 2014):

Change 7.6.16 [expr.cond] paragraph 2 as follows (this assumes the revised wording of the resolution of issue 1299 as the base text):

If either the second or the third operand has type void, one of the following shall hold:

  • The second or the third operand (but not both) is a (possibly parenthesized) throw-expression (14.2 [except.throw]); the result is of the type and value category of the other operand. The conditional-expression is a temporary expression if that operand is a temporary expression and is a bit-field if that operand is a bit-field.

  • ...

Date: 2014-01-25.00:00:00

Presumably the result of something like

    b ? x : throw y

is a bit-field if x is, but the current wording does not say that.

History
Date User Action Args
2017-02-06 00:00:00adminsetstatus: drwp -> cd4
2015-05-25 00:00:00adminsetstatus: dr -> drwp
2015-04-13 00:00:00adminsetmessages: + msg5351
2014-11-24 00:00:00adminsetstatus: ready -> dr
2014-03-03 00:00:00adminsetmessages: + msg4814
2014-01-25 00:00:00admincreate