summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaAttr.cpp
diff options
context:
space:
mode:
authorKevin P. Neal <kevin.neal@sas.com>2018-08-14 17:06:56 +0000
committerKevin P. Neal <kevin.neal@sas.com>2018-08-14 17:06:56 +0000
commit2c0bc8b7a3b2ac46c4cb166e2c360bbbdda6d698 (patch)
tree2810944b81e25fa5c56afd684a5ad43774fed688 /clang/lib/Sema/SemaAttr.cpp
parentba74d1c4ea2cc1322b73b8b141a9b99cda5669c9 (diff)
downloadbcm5719-llvm-2c0bc8b7a3b2ac46c4cb166e2c360bbbdda6d698.tar.gz
bcm5719-llvm-2c0bc8b7a3b2ac46c4cb166e2c360bbbdda6d698.zip
We have in place support for parsing #pragma FENV_ACCESS, but that
information is then discarded with a warning to the user that we don't support it. This patch gets us one step closer by getting the info down into the AST in most cases. Reviewed by: rsmith Differential Revision: https://reviews.llvm.org/D49865 llvm-svn: 339693
Diffstat (limited to 'clang/lib/Sema/SemaAttr.cpp')
-rw-r--r--clang/lib/Sema/SemaAttr.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/lib/Sema/SemaAttr.cpp b/clang/lib/Sema/SemaAttr.cpp
index 056d031fd83..8024e1a0515 100644
--- a/clang/lib/Sema/SemaAttr.cpp
+++ b/clang/lib/Sema/SemaAttr.cpp
@@ -773,6 +773,18 @@ void Sema::ActOnPragmaFPContract(LangOptions::FPContractModeKind FPC) {
}
}
+void Sema::ActOnPragmaFEnvAccess(LangOptions::FEnvAccessModeKind FPC) {
+ switch (FPC) {
+ case LangOptions::FEA_On:
+ FPFeatures.setAllowFEnvAccess();
+ break;
+ case LangOptions::FEA_Off:
+ FPFeatures.setDisallowFEnvAccess();
+ break;
+ }
+}
+
+
void Sema::PushNamespaceVisibilityAttr(const VisibilityAttr *Attr,
SourceLocation Loc) {
// Visibility calculations will consider the namespace's visibility.
OpenPOWER on IntegriCloud