=?utf-8?q?Tomáš?= Slanina <[email protected]>,
=?utf-8?q?Tomáš?= Slanina <[email protected]>,
=?utf-8?q?Tomáš?= Slanina <[email protected]>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/[email protected]>


================
@@ -518,12 +518,18 @@ opt<bool> PreambleParseForwardingFunctions{
     init(ParseOptions().PreambleParseForwardingFunctions),
 };
 
-opt<bool> SkipPreambleBuild{
+opt<ClangdServer::SkipPreambleBuildPolicy> SkipPreambleBuild{
     "skip-preamble-build",
     cat(Misc),
-    desc("If ture, skip preamble build"),
+    desc("Skip building the preamble"),
     Hidden,
-    init(ParseOptions().SkipPreambleBuild),
+    values(clEnumValN(ClangdServer::SkipPreambleBuildPolicy::Never, "never",
+                      "never skip"),
+           clEnumValN(ClangdServer::SkipPreambleBuildPolicy::Modules, 
"modules",
+                      "only if module use is encountered (default)"),
+           clEnumValN(ClangdServer::SkipPreambleBuildPolicy::Always, "always",
+                      "always skip")),
+    init(ClangdServer::SkipPreambleBuildPolicy::Modules),
----------------
ArcsinX wrote:

Previously we took default value from `ParseOptions()`, but with this change we 
set default value directly here. And as I can see, default value for 
`SkipPreambleBuild` is now `{}`, which means `Never`.
So, it looks like the default behavior of clangd as a library changes (despite 
the fact, that clangd executable behavior is still the same).

https://github.com/llvm/llvm-project/pull/229515
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to