4 ms·
The VAX. There's a bit in the condition codes register that indicates if overflow traps or not. Then there's the matter if ((char )0) causes a trap or not; on
by spc476 9y ago
The VAX. There's a bit in the condition codes register that indicates if overflow traps or not.
Then there's the matter if ((char )0) causes a trap or not; on systems without a MMU, it probably won't trap [1]. It's differences like overflow and memory references that cause most of the UB you see in C.
[1] On Linux, you can map a page to address 0. But that you can, doesn't mean you should.