[clang] [clang-cl] [Sema] Support MSVC non-const lvalue to user-defined temporary reference (PR #99833)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 20 04:49:44 PDT 2024
================
@@ -7272,6 +7272,11 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
CmdArgs.push_back("-fdelayed-template-parsing");
}
+ if (Args.hasFlag(options::OPT_fms_reference_binding,
+ options::OPT_fno_ms_reference_binding,
+ IsWindowsMSVC && !HaveCxx20))
----------------
zmodem wrote:
Could we do something better for the non-windows or c++20 cases?
We could emit a warning saying the flag is unsupported, or we could put those conditions first so that we don't call hasFlag, which would make clang warn about the unused option.
https://github.com/llvm/llvm-project/pull/99833
More information about the cfe-commits
mailing list