Skip to content

Commit 2e64206

Browse files
committed
[Parse] Sink registerParseRequestFunctions call into ParserUnit
1 parent 0a2f84e commit 2e64206

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

lib/Parse/Parser.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1115,6 +1115,8 @@ struct ParserUnit::Implementation {
11151115
TypeCheckerOpts(TyOpts), SILOpts(silOpts), Diags(SM),
11161116
Ctx(*ASTContext::get(LangOpts, TypeCheckerOpts, SILOpts, SearchPathOpts,
11171117
clangImporterOpts, symbolGraphOpts, SM, Diags)) {
1118+
registerParseRequestFunctions(Ctx.evaluator);
1119+
11181120
auto parsingOpts = SourceFile::getDefaultParsingOptions(LangOpts);
11191121
parsingOpts |= ParsingFlags::DisableDelayedBodies;
11201122
parsingOpts |= ParsingFlags::DisablePoundIfEvaluation;

tools/SourceKit/lib/SwiftLang/SwiftEditor.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -775,7 +775,6 @@ class SwiftDocumentSyntaxInfo {
775775
CompInv.getTypeCheckerOptions(), CompInv.getSILOptions(),
776776
CompInv.getModuleName()));
777777

778-
registerParseRequestFunctions(Parser->getParser().Context.evaluator);
779778
registerTypeCheckerRequestFunctions(
780779
Parser->getParser().Context.evaluator);
781780
registerClangImporterRequestFunctions(Parser->getParser().Context.evaluator);

tools/swift-ide-test/swift-ide-test.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2002,7 +2002,6 @@ static int doSyntaxColoring(const CompilerInvocation &InitInvok,
20022002
Invocation.getTypeCheckerOptions(), Invocation.getSILOptions(),
20032003
Invocation.getModuleName());
20042004

2005-
registerParseRequestFunctions(Parser.getParser().Context.evaluator);
20062005
registerTypeCheckerRequestFunctions(Parser.getParser().Context.evaluator);
20072006
registerClangImporterRequestFunctions(Parser.getParser().Context.evaluator);
20082007

@@ -2231,7 +2230,6 @@ static int doStructureAnnotation(const CompilerInvocation &InitInvok,
22312230
Invocation.getTypeCheckerOptions(),
22322231
Invocation.getSILOptions(), Invocation.getModuleName());
22332232

2234-
registerParseRequestFunctions(Parser.getParser().Context.evaluator);
22352233
registerTypeCheckerRequestFunctions(
22362234
Parser.getParser().Context.evaluator);
22372235
registerClangImporterRequestFunctions(Parser.getParser().Context.evaluator);

0 commit comments

Comments
 (0)