aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Driver/Tools.cpp
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2015-07-14 18:16:48 +0000
committerReid Kleckner <reid@kleckner.net>2015-07-14 18:16:48 +0000
commit5c6efed3f5cc85b55ea87e774b6a7701fe1d13df (patch)
treef25a08a28f5da735b37932f92effa0876ecf3032 /clang/lib/Driver/Tools.cpp
parent780e50187b94064416be1c0794482c4152ce5ee1 (diff)
downloadllvm-5c6efed3f5cc85b55ea87e774b6a7701fe1d13df.zip
llvm-5c6efed3f5cc85b55ea87e774b6a7701fe1d13df.tar.gz
llvm-5c6efed3f5cc85b55ea87e774b6a7701fe1d13df.tar.bz2
[clang-cl] Disable C++ exceptions a different way
Rather than making -fexceptions a core option that enables C++ EH in clang-cl, users can use the '-Xclang -fexceptions -Xclang -fcxx-exceptions' flag set. We weren't going to expose -fexceptions in clang-cl in the long run, so this way we don't add and then remove a flag. llvm-svn: 242176
Diffstat (limited to 'clang/lib/Driver/Tools.cpp')
-rw-r--r--clang/lib/Driver/Tools.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/clang/lib/Driver/Tools.cpp b/clang/lib/Driver/Tools.cpp
index d5ccc3c..8c11992 100644
--- a/clang/lib/Driver/Tools.cpp
+++ b/clang/lib/Driver/Tools.cpp
@@ -5086,13 +5086,9 @@ static EHFlags parseClangCLEHFlags(const Driver &D, const ArgList &Args) {
}
}
- // Only enable C++ exceptions if the user opts into it by passing
- // -fexceptions. Lots of build systems implicitly pass /EHsc when users don't
- // actually need it.
- // FIXME: Remove this when they work out of the box.
- if (!Args.hasFlag(options::OPT_fexceptions, options::OPT_fno_exceptions,
- /*default=*/false))
- EH = EHFlags();
+ // FIXME: Disable C++ EH completely, until it becomes more reliable. Users
+ // can use -Xclang to manually enable C++ EH until then.
+ EH = EHFlags();
return EH;
}