From 2cfc981860a0e68b8b066d69272171b38096f1b3 Mon Sep 17 00:00:00 2001 From: Marcus Tillmanns Date: Mon, 9 Jan 2023 10:26:48 +0100 Subject: [PATCH] ClangFormat: Remove setPath() from VFS setPath was not used anyway. It is also not available in older llvm versions. Change-Id: I16f0a8e2ffa827d92a2f1440d27391a51aefa728 Reviewed-by: hjk --- src/plugins/clangformat/llvmfilesystem.h | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/plugins/clangformat/llvmfilesystem.h b/src/plugins/clangformat/llvmfilesystem.h index 368439f4593..3589515ad35 100644 --- a/src/plugins/clangformat/llvmfilesystem.h +++ b/src/plugins/clangformat/llvmfilesystem.h @@ -19,8 +19,9 @@ class LlvmFileAdapter : public File { public: LlvmFileAdapter(const Twine &Path) - : m_path(FilePath::fromString(QString::fromStdString(Path.str()))) - {} + { + Q_UNUSED(Path); + } /// Destroy the file after closing it (if open). /// Sub-classes should generally call close() inside their destructors. We /// cannot do that from the base class, since close is virtual. @@ -60,13 +61,6 @@ public: std::error_code close() override { return {}; } protected: - // Set the file's underlying path. - void setPath(const Twine &Path) override - { - m_path = FilePath::fromString(QString::fromStdString(Path.str())); - } - - FilePath m_path; }; class LlvmFileSystemAdapter : public FileSystem