4 ms·
>what does "* ((int * )NULL)" do Technically speaking, that is undefined. "If an invalid value has been assigned to the pointer, the behavior of the unary * o
by gizmo686 13y ago
>what does "* ((int * )NULL)" do
Technically speaking, that is undefined.
"If an
invalid value has been assigned to the pointer, the behavior of the unary * operator is
undefined...Among the invalid values for dereferencing a pointer by the unary * operator are a null pointer,..."[1]
[1]http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf page 79
- bcantrill 13y agoYes, yes. What I actually do is write about a five line program which -- absent fancy alias disambiguation -- can't be optimized out of crashing. You're hired, okay? ;)