3 ms·
It is not possible for a trap representation to be made valid. A trap representation is one where getting it or setting it, other than as a raw byte, is undefin
by torstenvl 3y ago
It is not possible for a trap representation to be made valid. A trap representation is one where getting it or setting it, other than as a raw byte, is undefined behavior.
Section 6.2.6.1, paragraph 5, of C99, C11, C17, and—with a terminology change—the final draft of C23 are crystal clear on this.
- atq2119 3y agoI think you may be too hung up on the C(?) definition of trap representation. Clearly the OP suggestion isn't viable for default C integers anyway, and whichever language OP's suggestion is applied to is free to define the behavior of trap representations.