I just realized clang has this but clang does not support -fexec-charset. Clang Language Extensions — Clang 13 documentation (llvm.org)<https://clang.llvm.org/docs/LanguageExtensions.html>
__clang_literal_encoding__ Defined to a narrow string literal that represents the current encoding of narrow string literals, e.g., "hello". This macro typically expands to “UTF-8” (but may change in the future if the -fexec-charset="Encoding-Name" option is implemented.) __clang_wide_literal_encoding__ Defined to a narrow string literal that represents the current encoding of wide string literals, e.g., L"hello". This macro typically expands to “UTF-16” or “UTF-32” (but may change in the future if the -fwide-exec-charset="Encoding-Name" option is implemented.) I think we probably need macros like __gnuc_source_encoding__ __gnuc_literal_encoding__ __gnuc_wide_literal_encoding__ __gnuc_literal_encoding_is_ascii_based__ __gnuc_wide_literal_encoding_is_ascii_based__ In GCC Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10