[clang] [clang] Do not clear FP pragma stack when instantiating functions (PR #70646)

Serge Pavlov via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 30 22:47:59 PDT 2023


spavloff wrote:

Actually the pragma stack is not saved during template instantiation. It is saved during late template parsing using class `FpPragmaStackSaveRAII`. For template instantiation the dependency on the stack can be considered as an error, because all information about FP options should be taken from AST.

That was the reason for this issue - the pragma stack was cleared because `resetFPOptions` was introduced for late parsing. If instantiation was made during parsing, it spoiled the pragma stack.

https://github.com/llvm/llvm-project/pull/70646


More information about the cfe-commits mailing list