================
@@ -3845,6 +3845,17 @@ Sema::CheckBuiltinFunctionCall(FunctionDecl *FDecl, 
unsigned BuiltinID,
     if (BuiltinCountedByRef(TheCall))
       return ExprError();
     break;
+
+  case Builtin::BIfeclearexcept:
+  case Builtin::BIferaiseexcept:
+  case Builtin::BIfetestexcept:
+  case Builtin::BIfegetround:
+  case Builtin::BIfesetround:
+    if (!TheCall->getFPFeaturesInEffect(getLangOpts()).getAllowFEnvAccess() &&
+        getLangOpts().getFPExceptionMode() != LangOptions::FPE_MayTrap) {
----------------
efriedma-quic wrote:

I don't think you need to check getFPExceptionMode: the command-line flags 
should be processed as part of computing getFPFeaturesInEffect().

https://github.com/llvm/llvm-project/pull/187860
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to