================ @@ -77,10 +77,21 @@ static ToolChain::RTTIMode CalculateRTTIMode(const ArgList &Args, return NoRTTI ? ToolChain::RM_Disabled : ToolChain::RM_Enabled; } +static ToolChain::ExceptionsMode CalculateExceptionsMode(const ArgList &Args) { + + Arg *exceptionsArg = Args.getLastArg(options::OPT_fno_exceptions); + if (exceptionsArg && + exceptionsArg->getOption().matches(options::OPT_fno_exceptions)) { + return ToolChain::EM_Disabled; + } + return ToolChain::EM_Enabled; ---------------- mplatings wrote:
This is incorrect. There are plenty of examples across the clang code of how to check whether exceptions should be enabled or not. https://github.com/llvm/llvm-project/pull/75031 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits