This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 116a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2024-12-19


1102. Better example of undefined behavior

Section: 6.9.1  [intro.execution]     Status: C++11     Submitter: GB     Date: 2010-08-02

[Voted into the WP at the November, 2010 meeting.]

N3092 comment GB 6

There are core issues surrounding the undefined behavior of dereferencing a null pointer. It appears the intent is that dereferencing is well defined, but using the result of the dereference will yield undefined behavior. This topic is too confused to be the reference example of undefined behavior, or should be stated more precisely if it is to be retained.

(See also issue 232.)

Proposed resolution (September, 2010):

Change 6.9.1 [intro.execution] paragraph 4 as follows:

Certain other operations are described in this International Standard as undefined (for example, the effect of dereferencing the null pointer attempting to modify a const object). [Note:...