From 0bb3bcd0ef969bd3a3fb37826a0f8645d2795b96 Mon Sep 17 00:00:00 2001 From: Eric Fiselier Date: Sat, 27 May 2017 02:46:17 +0000 Subject: [coroutines] Support "coroutines" feature in module map requires clause Summary: In order for libc++ to add `` 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 --- clang/lib/Basic/Module.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'clang/lib/Basic/Module.cpp') 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(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) -- cgit v1.2.3