Revert "[coroutines] Support "coroutines" feature in module map requires clause"

This reverts commit r304054.

llvm-svn: 304057
This commit is contained in:
Eric Fiselier 2017-05-27 03:04:51 +00:00
parent 29d0f00340
commit 9208dd63ef
6 changed files with 1 additions and 30 deletions

View File

@ -413,9 +413,6 @@ altivec
blocks
The "blocks" language feature is available.
coroutines
Support for the coroutines TS is available.
cplusplus
C++ support is available.

View File

@ -64,7 +64,6 @@ 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)

View File

@ -1,3 +0,0 @@
#ifndef __cpp_coroutines
#error coroutines must be enabled
#endif

View File

@ -1,3 +0,0 @@
#ifdef __cpp_coroutines
#error coroutines must NOT be enabled
#endif

View File

@ -22,14 +22,7 @@ framework module DependsOnModule {
explicit module CustomReq2 {
requires custom_req2
}
explicit module Coroutines {
requires coroutines
header "coroutines.h"
}
explicit module NotCoroutines {
requires !coroutines
header "not_coroutines.h"
}
explicit framework module SubFramework {
umbrella header "SubFramework.h"

View File

@ -1,12 +0,0 @@
// RUN: rm -rf %t
// RUN: %clang_cc1 -Wauto-import -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -F %S/Inputs %s -verify
// RUN: %clang_cc1 -Wauto-import -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -F %S/Inputs %s -verify -fcoroutines-ts -DCOROUTINES
#ifdef COROUTINES
@import DependsOnModule.Coroutines;
@import DependsOnModule.NotCoroutines; // expected-error {{module 'DependsOnModule.NotCoroutines' is incompatible with feature 'coroutines'}}
#else
@import DependsOnModule.NotCoroutines;
@import DependsOnModule.Coroutines; // expected-error {{module 'DependsOnModule.Coroutines' requires feature 'coroutines'}}
#endif