[PATCH] D51009: [opt] Make OptTable::PrintHelp append "[options] <inputs>" conditionally

Jordan Rupprecht via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 21 22:38:48 PDT 2018


rupprecht requested changes to this revision.
rupprecht added a comment.
This revision now requires changes to proceed.

Some uses of this already use a space and probably don't want this behavior -- e.g. tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp invokes this w/ "clang -cc1". (There are a few others).

It seems like just checking for a space isn't a perfect signal for if this is a tool name or a full usage. Maybe there's another way, such as configuring (via a method or constructor arg in OptTable) whether the tool supports multiple inputs or multiple outputs?

Whatever you come up with, can you add a test case to unittests/Option/OptionParsingTest.cpp?


Repository:
  rL LLVM

https://reviews.llvm.org/D51009





More information about the llvm-commits mailing list