mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[SourceKit] Remove diagnostics path calculation
The diagnostic group documentation now point to the swift.org URL rather
than the toolchain path, so it no longer needs to be passed all the way
through sourcekitd.
Resolves rdar://151500502.
(cherry picked from commit 381684a389)
This commit is contained in:
@@ -283,10 +283,8 @@ class Session {
|
||||
public:
|
||||
Session(const std::string &SwiftExecutablePath,
|
||||
const std::string &RuntimeResourcePath,
|
||||
const std::string &DiagnosticDocumentationPath,
|
||||
std::shared_ptr<swift::PluginRegistry> Plugins)
|
||||
: Compiler(SwiftExecutablePath, RuntimeResourcePath,
|
||||
DiagnosticDocumentationPath, Plugins) {}
|
||||
: Compiler(SwiftExecutablePath, RuntimeResourcePath, Plugins) {}
|
||||
|
||||
bool
|
||||
performCompile(llvm::ArrayRef<const char *> Args,
|
||||
@@ -300,7 +298,6 @@ public:
|
||||
class SessionManager {
|
||||
const std::string &SwiftExecutablePath;
|
||||
const std::string &RuntimeResourcePath;
|
||||
const std::string &DiagnosticDocumentationPath;
|
||||
const std::shared_ptr<swift::PluginRegistry> Plugins;
|
||||
|
||||
llvm::StringMap<std::shared_ptr<Session>> sessions;
|
||||
@@ -311,12 +308,9 @@ class SessionManager {
|
||||
public:
|
||||
SessionManager(const std::string &SwiftExecutablePath,
|
||||
const std::string &RuntimeResourcePath,
|
||||
const std::string &DiagnosticDocumentationPath,
|
||||
const std::shared_ptr<swift::PluginRegistry> Plugins)
|
||||
: SwiftExecutablePath(SwiftExecutablePath),
|
||||
RuntimeResourcePath(RuntimeResourcePath),
|
||||
DiagnosticDocumentationPath(DiagnosticDocumentationPath),
|
||||
Plugins(Plugins) {}
|
||||
RuntimeResourcePath(RuntimeResourcePath), Plugins(Plugins) {}
|
||||
|
||||
std::shared_ptr<Session> getSession(StringRef name);
|
||||
|
||||
@@ -342,7 +336,6 @@ class SwiftLangSupport : public LangSupport {
|
||||
/// Used to find clang relative to it.
|
||||
std::string SwiftExecutablePath;
|
||||
std::string RuntimeResourcePath;
|
||||
std::string DiagnosticDocumentationPath;
|
||||
std::shared_ptr<SwiftASTManager> ASTMgr;
|
||||
std::shared_ptr<SwiftEditorDocumentFileMap> EditorDocuments;
|
||||
std::shared_ptr<RequestTracker> ReqTracker;
|
||||
@@ -366,9 +359,6 @@ public:
|
||||
}
|
||||
|
||||
StringRef getRuntimeResourcePath() const { return RuntimeResourcePath; }
|
||||
StringRef getDiagnosticDocumentationPath() const {
|
||||
return DiagnosticDocumentationPath;
|
||||
}
|
||||
|
||||
std::shared_ptr<SwiftASTManager> getASTManager() { return ASTMgr; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user