[PATCH] D59503: [llvm-ar] Support N [count] modifier

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 18 13:15:54 PDT 2019


ruiu added a comment.

Wow, this option is too good... I'm using Unix more than 20 years now but didn't know this option existed. In rare occasions where I had to extract a file with a duplicate name, I opened an archive file using a binary editor and rename a file name before extracting.



================
Comment at: llvm/tools/llvm-ar/llvm-ar.cpp:194
+// match for extract/delete operations when there are multiple matches. This is
+// 1-indexed.
+static int CountParam;
----------------
If this is 1-indexed, you could use `0` to indicate that the option was not given, which allows you to remove `UseCountParam`. (But this is perhaps more like a personal preference, so you can ignore this comment.)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D59503





More information about the llvm-commits mailing list