3 ms·
clang warns about this particular usage of a null constant: warning: indirection of non-volatile null pointer will be deleted, not trap [-Wnull-dereference]
by cpeterso 11y ago
clang warns about this particular usage of a null constant:
warning: indirection of non-volatile null pointer will be deleted, not trap [-Wnull-dereference]
return (int)0;
^~~~~~~~
note: consider using __builtin_trap() or qualifying pointer with 'volatile'
- qb45 11y ago> warning: indirection of non-volatile null pointer will be deleted, not trap That's a sweet little optimization :) Probably the only reason they don't abort compilation at this point is that someone complained when it broke his tricky little macro which sometimes generates unreachable null dereference. Or something like that.