3 ms·
> Unspecified behaviour would require the standard to give a set of possible outcomes I don't think there is a requirement that the possible unspecified behavi
by aw1621107 3y ago
> Unspecified behaviour would require the standard to give a set of possible outcomes
I don't think there is a requirement that the possible unspecified behaviors are enumerated. The current C++ draft [0] states possible behaviors are "usually" enumerated, but "usually" is not "always", and there's no explicit direction that those behaviors are the only allowable options.
There's also the definition from the C89 spec which doesn't even have that language, only stating that the standard imposes no requirements on the unspecified behavior [1].
[0]: https://eel.is/c++draft/intro.defs#defns.unspecified https://eel.is/c++draft/intro.defs#defns.unspecified
[1]: http://port70.net/%7Ensz/c/c89/c89-draft.html#1.6 http://port70.net/%7Ensz/c/c89/c89-draft.html#1.6