Remove dependence on <ciso646> (#73273)

C++23 removed `<ciso646>` from the standard library. The header is used
in two places: Once in order to pull in standard library macros. Since
this file also includes `<optional>`, that use of `<ciso646>` is
technically redundant, but should probably be left in in case a future
change ever removes the include of `<optional>`. A second use of
`<ciso646>` appears to have been introduced in
da650094b187ee3c8017d74f63c885663faca1d8, but seems unnecessary (the
file doesn't seem to use anything from that header, and it seems to
build just fine on MSVC here without it). The new `<version>` header
should be supported by all supported implementations. This change
replaces uses of `<ciso646>` with the `<version>` header, or removes
them entirely where unnecessary.
This commit is contained in:
Michael Kenzel 2025-02-09 03:48:01 +01:00 committed by GitHub
parent 10ed0e4065
commit c89735d289
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -19,6 +19,7 @@
#include "llvm/Config/llvm-config.h" // for LLVM_ON_UNIX
#include "llvm/Support/Compiler.h"
#include <optional>
#include <version>
#if defined(_MSC_VER)
// MSVC's call_once implementation worked since VS 2015, which is the minimum