aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Driver/Tools.cpp
diff options
context:
space:
mode:
authorGor Nishanov <GorNishanov@gmail.com>2016-10-02 03:31:58 +0000
committerGor Nishanov <GorNishanov@gmail.com>2016-10-02 03:31:58 +0000
commit4ffb434ca870674c67c106c40f13d322361384c9 (patch)
treea72bc534d135a38d97220f0cf6392119df5d2760 /clang/lib/Driver/Tools.cpp
parente84372b039e1d965fe27d978e38f27c585dd3185 (diff)
downloadllvm-4ffb434ca870674c67c106c40f13d322361384c9.zip
llvm-4ffb434ca870674c67c106c40f13d322361384c9.tar.gz
llvm-4ffb434ca870674c67c106c40f13d322361384c9.tar.bz2
[coroutines] Rename driver flag -fcoroutines to -fcoroutines-ts
Summary: Also makes -fcoroutines_ts to be both a Driver and CC1 flag. Patch mostly by EricWF. Reviewers: rnk, cfe-commits, rsmith, EricWF Subscribers: mehdi_amini Differential Revision: https://reviews.llvm.org/D25130 llvm-svn: 283064
Diffstat (limited to 'clang/lib/Driver/Tools.cpp')
-rw-r--r--clang/lib/Driver/Tools.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Driver/Tools.cpp b/clang/lib/Driver/Tools.cpp
index 97ffd2b..5138d75 100644
--- a/clang/lib/Driver/Tools.cpp
+++ b/clang/lib/Driver/Tools.cpp
@@ -5416,6 +5416,12 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
CmdArgs.push_back("-fblocks-runtime-optional");
}
+ if (Args.hasFlag(options::OPT_fcoroutines_ts, options::OPT_fno_coroutines_ts,
+ false) &&
+ types::isCXX(InputType)) {
+ CmdArgs.push_back("-fcoroutines-ts");
+ }
+
// -fmodules enables the use of precompiled modules (off by default).
// Users can pass -fno-cxx-modules to turn off modules support for
// C++/Objective-C++ programs.