summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2017-03-27 19:17:25 +0000
committerAdam Nemet <anemet@apple.com>2017-03-27 19:17:25 +0000
commit484aa45153e6fe429200034380e07966fe601003 (patch)
tree6bcc904388c8c6c8138d7d94759ea2f85b3c658f /clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
parent97e4f472c35d16dea12372d6ec51422216d3ad17 (diff)
downloadbcm5719-llvm-484aa45153e6fe429200034380e07966fe601003.tar.gz
bcm5719-llvm-484aa45153e6fe429200034380e07966fe601003.zip
Encapsulate FPOptions and use it consistently
Sema holds the current FPOptions which is adjusted by 'pragma STDC FP_CONTRACT'. This then gets propagated into expression nodes as they are built. This encapsulates FPOptions so that this propagation happens opaquely rather than directly with the fp_contractable on/off bit. This allows controlled transitioning of fp_contractable to a ternary value (off, on, fast). It will also allow adding more fast-math flags later. This is toward moving fp-contraction=fast from an LLVM TargetOption to a FastMathFlag in order to fix PR25721. Differential Revision: https://reviews.llvm.org/D31166 llvm-svn: 298877
Diffstat (limited to 'clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp')
-rw-r--r--clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp b/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
index e6469f53d46..8871bb7e831 100644
--- a/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
+++ b/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
@@ -7500,7 +7500,7 @@ Stmt *RewriteModernObjC::RewriteObjCIvarRefExpr(ObjCIvarRefExpr *IV) {
BinaryOperator *addExpr =
new (Context) BinaryOperator(castExpr, DRE, BO_Add,
Context->getPointerType(Context->CharTy),
- VK_RValue, OK_Ordinary, SourceLocation(), false);
+ VK_RValue, OK_Ordinary, SourceLocation(), FPOptions());
// Don't forget the parens to enforce the proper binding.
ParenExpr *PE = new (Context) ParenExpr(SourceLocation(),
SourceLocation(),
OpenPOWER on IntegriCloud