4 ms·
> &mem[65536] must be a valid pointer value explain
by im3w1l 5y ago
> &mem[65536] must be a valid pointer value
explain
- Joker_vD 5y agoC99 draft, 6.5.6.8: Moreover, if the expression P points to the last element of an array object, the expression (P)+1 points one past the last element of the array object, and if the expression Q points one past the last element of an array object, the expression (Q)-1 points to the last element of the array object. If both the pointer operand and the result point to elements of the same array object, or one past the last element of the array object, the evaluation shall not produce an overflow; otherwise, the behavior is undefined. If the result points one past the last element of the array object, it shall not be used as the operand of a unary * operator that is evaluated.