[clang-tools-extra] r361800 - [clangd] Never end command-line flag description with a period. NFC
Ilya Biryukov via cfe-commits
cfe-commits at lists.llvm.org
Tue May 28 02:31:27 PDT 2019
Author: ibiryukov
Date: Tue May 28 02:31:27 2019
New Revision: 361800
URL: http://llvm.org/viewvc/llvm-project?rev=361800&view=rev
Log:
[clangd] Never end command-line flag description with a period. NFC
For consistency. Not having a period at the end is much more common and
seems to be the preferred style for command-line options.
Modified:
clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp
Modified: clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp?rev=361800&r1=361799&r2=361800&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp (original)
+++ clang-tools-extra/trunk/clangd/tool/ClangdMain.cpp Tue May 28 02:31:27 2019
@@ -37,14 +37,14 @@ namespace clangd {
// FIXME: remove this option when Dex is cheap enough.
static llvm::cl::opt<bool>
UseDex("use-dex-index",
- llvm::cl::desc("Use experimental Dex dynamic index."),
+ llvm::cl::desc("Use experimental Dex dynamic index"),
llvm::cl::init(true), llvm::cl::Hidden);
static llvm::cl::opt<Path> CompileCommandsDir(
"compile-commands-dir",
llvm::cl::desc("Specify a path to look for compile_commands.json. If path "
"is invalid, clangd will look in the current directory and "
- "parent paths of each source file."));
+ "parent paths of each source file"));
static llvm::cl::opt<unsigned>
WorkerThreadsCount("j",
@@ -59,10 +59,10 @@ static llvm::cl::opt<CompletionStyleFlag
llvm::cl::values(
clEnumValN(Detailed, "detailed",
"One completion item for each semantically distinct "
- "completion, with full type information."),
+ "completion, with full type information"),
clEnumValN(Bundled, "bundled",
"Similar completion items (e.g. function overloads) are "
- "combined. Type information shown where possible.")),
+ "combined. Type information shown where possible")),
llvm::cl::init(Detailed));
// FIXME: Flags are the wrong mechanism for user preferences.
@@ -98,12 +98,12 @@ static llvm::cl::opt<bool>
Test("lit-test",
llvm::cl::desc("Abbreviation for -input-style=delimited -pretty -sync "
"-enable-test-scheme -log=verbose."
- "Intended to simplify lit tests."),
+ "Intended to simplify lit tests"),
llvm::cl::init(false), llvm::cl::Hidden);
static llvm::cl::opt<bool> EnableTestScheme(
"enable-test-uri-scheme",
- llvm::cl::desc("Enable 'test:' URI scheme. Only use in lit tests."),
+ llvm::cl::desc("Enable 'test:' URI scheme. Only use in lit tests"),
llvm::cl::init(false), llvm::cl::Hidden);
enum PCHStorageFlag { Disk, Memory };
@@ -119,7 +119,7 @@ static llvm::cl::opt<PCHStorageFlag> PCH
static llvm::cl::opt<int> LimitResults(
"limit-results",
llvm::cl::desc("Limit the number of results returned by clangd. "
- "0 means no limit. (default=100)"),
+ "0 means no limit (default=100)"),
llvm::cl::init(100));
static llvm::cl::opt<bool>
@@ -134,7 +134,7 @@ static llvm::cl::opt<Path>
static llvm::cl::opt<Path> InputMirrorFile(
"input-mirror-file",
llvm::cl::desc(
- "Mirror all LSP input to the specified file. Useful for debugging."),
+ "Mirror all LSP input to the specified file. Useful for debugging"),
llvm::cl::init(""), llvm::cl::Hidden);
static llvm::cl::opt<bool> EnableIndex(
@@ -142,7 +142,7 @@ static llvm::cl::opt<bool> EnableIndex(
llvm::cl::desc(
"Enable index-based features. By default, clangd maintains an index "
"built from symbols in opened files. Global index support needs to "
- "enabled separatedly."),
+ "enabled separatedly"),
llvm::cl::init(true), llvm::cl::Hidden);
static llvm::cl::opt<bool> AllScopesCompletion(
@@ -151,7 +151,7 @@ static llvm::cl::opt<bool> AllScopesComp
"If set to true, code completion will include index symbols that are "
"not defined in the scopes (e.g. "
"namespaces) visible from the code completion point. Such completions "
- "can insert scope qualifiers."),
+ "can insert scope qualifiers"),
llvm::cl::init(true));
static llvm::cl::opt<bool> ShowOrigins(
@@ -167,7 +167,7 @@ static llvm::cl::opt<CodeCompleteOptions
"Include what you use. "
"Insert the owning header for top-level symbols, unless the "
"header is already directly included or the symbol is "
- "forward-declared."),
+ "forward-declared"),
clEnumValN(
CodeCompleteOptions::NeverInsert, "never",
"Never insert #include directives as part of code completion")));
@@ -176,16 +176,16 @@ static llvm::cl::opt<bool> HeaderInserti
"header-insertion-decorators",
llvm::cl::desc("Prepend a circular dot or space before the completion "
"label, depending on whether "
- "an include line will be inserted or not."),
+ "an include line will be inserted or not"),
llvm::cl::init(true));
static llvm::cl::opt<Path> IndexFile(
"index-file",
llvm::cl::desc(
"Index file to build the static index. The file must have been created "
- "by a compatible clangd-indexer.\n"
+ "by a compatible clangd-indexer\n"
"WARNING: This option is experimental only, and will be removed "
- "eventually. Don't rely on it."),
+ "eventually. Don't rely on it"),
llvm::cl::init(""), llvm::cl::Hidden);
static llvm::cl::opt<bool> EnableBackgroundIndex(
@@ -200,7 +200,7 @@ static llvm::cl::opt<int> BackgroundInde
llvm::cl::desc(
"If set to non-zero, the background index rebuilds the symbol index "
"periodically every X milliseconds; otherwise, the "
- "symbol index will be updated for each indexed file."),
+ "symbol index will be updated for each indexed file"),
llvm::cl::init(5000), llvm::cl::Hidden);
enum CompileArgsFrom { LSPCompileArgs, FilesystemCompileArgs };
@@ -218,19 +218,19 @@ static llvm::cl::opt<bool> EnableFunctio
"function-arg-placeholders",
llvm::cl::desc("When disabled, completions contain only parentheses for "
"function calls. When enabled, completions also contain "
- "placeholders for method parameters."),
+ "placeholders for method parameters"),
llvm::cl::init(CodeCompleteOptions().EnableFunctionArgSnippets));
static llvm::cl::opt<std::string> ClangTidyChecks(
"clang-tidy-checks",
llvm::cl::desc(
"List of clang-tidy checks to run (this will override "
- ".clang-tidy files). Only meaningful when -clang-tidy flag is on."),
+ ".clang-tidy files). Only meaningful when -clang-tidy flag is on"),
llvm::cl::init(""));
static llvm::cl::opt<bool>
EnableClangTidy("clang-tidy",
- llvm::cl::desc("Enable clang-tidy diagnostics."),
+ llvm::cl::desc("Enable clang-tidy diagnostics"),
llvm::cl::init(true));
static llvm::cl::opt<std::string>
@@ -242,13 +242,13 @@ static llvm::cl::opt<std::string>
static llvm::cl::opt<bool> SuggestMissingIncludes(
"suggest-missing-includes",
llvm::cl::desc("Attempts to fix diagnostic errors caused by missing "
- "includes using index."),
+ "includes using index"),
llvm::cl::init(true));
static llvm::cl::opt<OffsetEncoding> ForceOffsetEncoding(
"offset-encoding",
llvm::cl::desc("Force the offsetEncoding used for character positions. "
- "This bypasses negotiation via client capabilities."),
+ "This bypasses negotiation via client capabilities"),
llvm::cl::values(clEnumValN(OffsetEncoding::UTF8, "utf-8",
"Offsets are in UTF-8 bytes"),
clEnumValN(OffsetEncoding::UTF16, "utf-16",
More information about the cfe-commits
mailing list