Created on2011-05-07.00:00:00 last changed145 months ago
[Voted into the WP at the February, 2012 meeting;moved to DR at the October, 2012 meeting.]
Proposed resolution (August, 2011):
Change 7.7 [expr.const] paragraph 2 as follows:
...
a result that is not mathematically defined or not in therange of representable values for its type;
an operation that would have undefined behavior[Note: including, for example, signed integer overflow (Clause 7 [expr]), certain pointer arithmetic (7.6.6 [expr.add]), division by zero (7.6.5 [expr.mul]), or certainshift operations (7.6.7 [expr.shift]) —endnote];
...
a subtraction (7.6.6 [expr.add]) where bothoperands are pointers;
...
The requirements for constant expressions do not currently,but should, exclude expressions that have undefined behavior, such aspointer arithmetic when the pointers do not point to elements of thesame array.
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2014-03-03 00:00:00 | admin | set | status: drwp -> cd3 |
| 2012-11-03 00:00:00 | admin | set | status: dr -> drwp |
| 2012-09-24 00:00:00 | admin | set | messages: +msg4002 |
| 2012-09-24 00:00:00 | admin | set | messages: +msg4001 |
| 2012-09-24 00:00:00 | admin | set | status: review -> dr |
| 2012-02-27 00:00:00 | admin | set | status: ready -> review |
| 2011-05-07 00:00:00 | admin | create | |