aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/AST/DeclPrinter.cpp2
-rw-r--r--lib/Basic/IdentifierTable.cpp2
-rw-r--r--lib/Lex/PPDirectives.cpp2
-rw-r--r--lib/Lex/Preprocessor.cpp12
-rw-r--r--lib/Parse/ParseObjc.cpp2
-rw-r--r--lib/Parse/Parser.cpp2
6 files changed, 11 insertions, 11 deletions
diff --git a/lib/AST/DeclPrinter.cpp b/lib/AST/DeclPrinter.cpp
index 32bdba1a0b..74e1c1bb9d 100644
--- a/lib/AST/DeclPrinter.cpp
+++ b/lib/AST/DeclPrinter.cpp
@@ -650,7 +650,7 @@ void DeclPrinter::VisitFileScopeAsmDecl(FileScopeAsmDecl *D) {
}
void DeclPrinter::VisitImportDecl(ImportDecl *D) {
- Out << "@import " << D->getImportedModule()->getFullModuleName()
+ Out << "@__experimental_modules_import " << D->getImportedModule()->getFullModuleName()
<< ";\n";
}
diff --git a/lib/Basic/IdentifierTable.cpp b/lib/Basic/IdentifierTable.cpp
index 8bd76252b3..8945c2f47c 100644
--- a/lib/Basic/IdentifierTable.cpp
+++ b/lib/Basic/IdentifierTable.cpp
@@ -41,7 +41,7 @@ IdentifierInfo::IdentifierInfo() {
ChangedAfterLoad = false;
RevertedTokenID = false;
OutOfDate = false;
- IsImport = false;
+ IsModulesImport = false;
FETokenInfo = 0;
Entry = 0;
}
diff --git a/lib/Lex/PPDirectives.cpp b/lib/Lex/PPDirectives.cpp
index 0364e4279a..b08bcffd20 100644
--- a/lib/Lex/PPDirectives.cpp
+++ b/lib/Lex/PPDirectives.cpp
@@ -1401,7 +1401,7 @@ void Preprocessor::HandleIncludeDirective(SourceLocation HashLoc,
Diag(HashLoc, diag::warn_auto_module_import)
<< IncludeKind << PathString
<< FixItHint::CreateReplacement(ReplaceRange,
- "@import " + PathString.str().str() + ";");
+ "@__experimental_modules_import " + PathString.str().str() + ";");
}
// Load the module.
diff --git a/lib/Lex/Preprocessor.cpp b/lib/Lex/Preprocessor.cpp
index 96dfe36006..b6ea65de49 100644
--- a/lib/Lex/Preprocessor.cpp
+++ b/lib/Lex/Preprocessor.cpp
@@ -565,13 +565,13 @@ void Preprocessor::HandleIdentifier(Token &Identifier) {
if (II.isExtensionToken() && !DisableMacroExpansion)
Diag(Identifier, diag::ext_token_used);
- // If this is the 'import' contextual keyword, note that the next token
- // indicates a module name.
+ // If this is the '__experimental_modules_import' contextual keyword, note
+ // that the next token indicates a module name.
//
- // Note that we do not treat 'import' as a contextual keyword when we're
- // in a caching lexer, because caching lexers only get used in contexts where
- // import declarations are disallowed.
- if (II.isImport() && !InMacroArgs && !DisableMacroExpansion &&
+ // Note that we do not treat '__experimental_modules_import' as a contextual
+ // keyword when we're in a caching lexer, because caching lexers only get
+ // used in contexts where import declarations are disallowed.
+ if (II.isModulesImport() && !InMacroArgs && !DisableMacroExpansion &&
getLangOptions().Modules && CurLexerKind != CLK_CachingLexer) {
ModuleImportLoc = Identifier.getLocation();
ModuleImportPath.clear();
diff --git a/lib/Parse/ParseObjc.cpp b/lib/Parse/ParseObjc.cpp
index b135bba488..eea9a7e981 100644
--- a/lib/Parse/ParseObjc.cpp
+++ b/lib/Parse/ParseObjc.cpp
@@ -64,7 +64,7 @@ Parser::DeclGroupPtrTy Parser::ParseObjCAtDirectives() {
case tok::objc_dynamic:
SingleDecl = ParseObjCPropertyDynamic(AtLoc);
break;
- case tok::objc_import:
+ case tok::objc___experimental_modules_import:
if (getLang().Modules)
return ParseModuleImport(AtLoc);
diff --git a/lib/Parse/Parser.cpp b/lib/Parse/Parser.cpp
index 6927c50b8f..6a479bc60c 100644
--- a/lib/Parse/Parser.cpp
+++ b/lib/Parse/Parser.cpp
@@ -1609,7 +1609,7 @@ void Parser::ParseMicrosoftIfExistsExternalDeclaration() {
}
Parser::DeclGroupPtrTy Parser::ParseModuleImport(SourceLocation AtLoc) {
- assert(Tok.isObjCAtKeyword(tok::objc_import) &&
+ assert(Tok.isObjCAtKeyword(tok::objc___experimental_modules_import) &&
"Improper start to module import");
SourceLocation ImportLoc = ConsumeToken();