[clang-tools-extra] r365632 - [clangd] Trim spaces around parsed include in include extractor

Kadir Cetinkaya via cfe-commits cfe-commits at lists.llvm.org
Wed Jul 10 06:59:13 PDT 2019


Author: kadircet
Date: Wed Jul 10 06:59:13 2019
New Revision: 365632

URL: http://llvm.org/viewvc/llvm-project?rev=365632&view=rev
Log:
[clangd] Trim spaces around parsed include in include extractor

Modified:
    clang-tools-extra/trunk/clangd/QueryDriverDatabase.cpp

Modified: clang-tools-extra/trunk/clangd/QueryDriverDatabase.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/QueryDriverDatabase.cpp?rev=365632&r1=365631&r2=365632&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/QueryDriverDatabase.cpp (original)
+++ clang-tools-extra/trunk/clangd/QueryDriverDatabase.cpp Wed Jul 10 06:59:13 2019
@@ -76,7 +76,7 @@ std::vector<std::string> parseDriverOutp
   }
 
   for (llvm::StringRef Line : llvm::make_range(StartIt, EndIt)) {
-    SystemIncludes.push_back(Line.str());
+    SystemIncludes.push_back(Line.trim().str());
     vlog("System include extraction: adding {0}", Line);
   }
   return SystemIncludes;




More information about the cfe-commits mailing list