https://github.com/AaronBallman commented:
C90 was published in 1990 and WG14 began working on defects. They rolled those defect fixes up into three separate documents, [ISO/IEC 9899:1990/Amd 1:1995](https://www.iso.org/standard/23909.html), [ISO/IEC 9899:1990/Cor 1:1994](https://www.iso.org/standard/24271.html), and [ISO/IEC 9899:1990/Cor 2:1996](https://www.iso.org/standard/27110.html) which started being colloquially called either C94 or C95, but WG14 calls it C95: https://www.open-std.org/jtc1/sc22/wg14/www/projects.html COR1 and COR2 were purely bug fixes. AMD1 had normative changes (they added digraph support and `__STDC_VERSION__` as a macro) and so it's a stand-alone standard version. Clang implements these differences between C90 and C95 correctly, but we go the extra mile too: we set `__STDC_VERSION__` to `199409L` if in C90 mode with Digraphs enabled: https://godbolt.org/z/E4eKTYsKW GCC does not support `-fdigraphs` and so they don't have this behavior. `iso9899:199409` should be wrong, that's not an ISO publication value but for some reason GCC has this spelling: https://godbolt.org/z/1YexGaMnE So I've convinced myself it's worth keeping the standard mode itself without updating the way it's spelled to drop the `09`, but I don't see why we wouldn't reference C95 at all given that it's a language mode we do support. I would rather we document this odd difference so it's easier for users to know what's going on. https://github.com/llvm/llvm-project/pull/206403 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
