Merge pull request #31521 from owenv/sourcekit-find-edu-notes

[SourceKit] Discover diagnostic documentation relative to sourcekitd
This commit is contained in:
Owen Voorhees
2020-05-06 19:54:02 -05:00
committed by GitHub
13 changed files with 108 additions and 43 deletions

View File

@@ -36,12 +36,16 @@ unsigned GlobalConfig::getCompletionCheckDependencyInterval() const {
return State.CompletionCheckDependencyInterval;
}
SourceKit::Context::Context(StringRef RuntimeLibPath,
SourceKit::Context::Context(
StringRef RuntimeLibPath, StringRef DiagnosticDocumentationPath,
llvm::function_ref<std::unique_ptr<LangSupport>(Context &)>
LangSupportFactoryFn,
bool shouldDispatchNotificationsOnMain) : RuntimeLibPath(RuntimeLibPath),
NotificationCtr(new NotificationCenter(shouldDispatchNotificationsOnMain)),
Config(new GlobalConfig()) {
LangSupportFactoryFn,
bool shouldDispatchNotificationsOnMain)
: RuntimeLibPath(RuntimeLibPath),
DiagnosticDocumentationPath(DiagnosticDocumentationPath),
NotificationCtr(
new NotificationCenter(shouldDispatchNotificationsOnMain)),
Config(new GlobalConfig()) {
// Should be called last after everything is initialized.
SwiftLang = LangSupportFactoryFn(*this);
}