- Title
- Parenthesized throw-expression operand of conditional-expression
- Status
- cd3
- Section
- 7.6.16 [expr.cond]
- Submitter
- Nikolay Ivchenkov
Created on 2012-09-04.00:00:00 last changed 152 months ago
Messages
Date: 2013-04-15.00:00:00
[Moved to DR at the April, 2013 meeting.]
Date: 2012-10-15.00:00:00
Proposed resolution (October, 2012): Change 7.6.16 [expr.cond] paragraph 2 as follows: If either the second or the third operand has type void ,
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 ... (This resolution also resolves issue 1560.)
then the lvalue-to-rvalue (7.3.2 [conv.lval]), array-to-pointer
(7.3.3 [conv.array]), and function-to-pointer (7.3.4 [conv.func]) standard conversions are performed on the second and
third operands, and one of the following shall hold:
and is a prvalue.
Date: 2026-07-25.21:52:10
The current wording of 7.6.16 [expr.cond] paragraph 2 says, If either the second or the third operand has type void ,
then the lvalue-to-rvalue (7.3.2 [conv.lval]), array-to-pointer
(7.3.3 [conv.array]), and function-to-pointer (7.3.4 [conv.func]) standard conversions are performed on the second and
third operands, and one of the following shall hold: The second or the third operand (but not both) is a
throw-expression (14.2 [except.throw]); the result is of
the type of the other and is a prvalue. Both the second and the third operands have type void ; the
result is of type void and is a prvalue. [Note: This
includes the case where both operands are throw-expressions.
—end note] A parenthesized throw-expression is a
primary-expression, not a throw-expression. Should a
parenthesized throw-expression be considered a
throw-expression for this purpose?
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2014-03-03 00:00:00 | admin | set | status: drwp -> cd3 |
| 2013-10-14 00:00:00 | admin | set | status: dr -> drwp |
| 2013-05-03 00:00:00 | admin | set | messages: + msg4389 |
| 2013-05-03 00:00:00 | admin | set | status: ready -> dr |
| 2012-11-03 00:00:00 | admin | set | messages: + msg4052 |
| 2012-11-03 00:00:00 | admin | set | status: open -> ready |
| 2012-09-04 00:00:00 | admin | create | |