diff options
author | Eric Fiselier <eric@efcs.ca> | 2017-05-27 02:46:17 +0000 |
---|---|---|
committer | Eric Fiselier <eric@efcs.ca> | 2017-05-27 02:46:17 +0000 |
commit | 0bb3bcd0ef969bd3a3fb37826a0f8645d2795b96 (patch) | |
tree | 5a441fcdade31181f2f99441f19d3c73393df13e /clang/lib/Basic/Module.cpp | |
parent | cbc82b3ca93d845daaceff035aff252cea5e753e (diff) | |
download | bcm5719-llvm-0bb3bcd0ef969bd3a3fb37826a0f8645d2795b96.tar.gz bcm5719-llvm-0bb3bcd0ef969bd3a3fb37826a0f8645d2795b96.zip |
[coroutines] Support "coroutines" feature in module map requires clause
Summary: In order for libc++ to add `<experimental/coroutine>` to its module map, there has to be a feature that can be used to detect if coroutines support is enabled in Clang.
Reviewers: rsmith
Reviewed By: rsmith
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D33538
llvm-svn: 304054
Diffstat (limited to 'clang/lib/Basic/Module.cpp')
-rw-r--r-- | clang/lib/Basic/Module.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Basic/Module.cpp b/clang/lib/Basic/Module.cpp index a6fd931cb17..ac3d7c55967 100644 --- a/clang/lib/Basic/Module.cpp +++ b/clang/lib/Basic/Module.cpp @@ -64,6 +64,7 @@ static bool hasFeature(StringRef Feature, const LangOptions &LangOpts, bool HasFeature = llvm::StringSwitch<bool>(Feature) .Case("altivec", LangOpts.AltiVec) .Case("blocks", LangOpts.Blocks) + .Case("coroutines", LangOpts.CoroutinesTS) .Case("cplusplus", LangOpts.CPlusPlus) .Case("cplusplus11", LangOpts.CPlusPlus11) .Case("freestanding", LangOpts.Freestanding) |