← Back to context

Comment by mitxela

12 hours ago

The standards intended interpretation of UB was always intended to be something like "implementation defined, no documentation required" to allow for implementation weirdness, even unpredictable ones. It was compiler authors who decided do abuse this allowance to do really unintuitive things instead of weird platform weirdness.

100% There are implementations that have sane behavior for "UB" instead of making it an excuse to misbehave.

The ISO standard is not the same as a language from a single vendor.