[PATCH] D124445: [llvm-ar] Modify usage printouts to use the correct toolname

Chris Jackson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 27 09:25:32 PDT 2022


chrisjackson added inline comments.


================
Comment at: llvm/test/tools/llvm-ar/tool-name.test:18
+# SUFFIX: USAGE: ar
+# ARM: arm-pokymllib32-linux-gnueabi-llvm-ar-9
----------------
jhenderson wrote:
> What's the purpose of this line? To show that the prefix is printed as much as the suffix, or something more specific?
> 
> Also, it's missing "USAGE:" unlike the other patterns.
looking at https://github.com/llvm/llvm-project/commit/4d53b99c5df2c83172d23521d1b1ab8361d6de92, this exists because the tool selection heuristic would mistakenly think it was 'llvm-lib', so I have retained this check.


================
Comment at: llvm/tools/llvm-ar/llvm-ar.cpp:66
+static void printRanLibHelp(StringRef ToolName) {
+  outs() << "OVERVIEW: LLVM Ranlib (" + ToolName + ")\n\n"
+         << "This program generates an index to speed access to archives\n\n"
----------------
MaskRay wrote:
> `printArHelp` omits ToolName on the OVERVIEW line. Omit it here?
Agreed, removed for consistency,


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D124445/new/

https://reviews.llvm.org/D124445



More information about the llvm-commits mailing list