OSDN Git Service

Putting all the standard tool options into a "Generic" category.
authorChris Bieneman <beanz@apple.com>
Mon, 26 Jan 2015 16:56:00 +0000 (16:56 +0000)
committerChris Bieneman <beanz@apple.com>
Mon, 26 Jan 2015 16:56:00 +0000 (16:56 +0000)
commite0c2d280a2cb39ac23af40fba6794e78d95e29bf
treecd7676d7ea164a486a9468fb96682f14fcf3c6e7
parent1e0dc31134bd6ec08a10f25a1e817b3510ac3d40
Putting all the standard tool options into a "Generic" category.

Summary:
This puts all the options that CommandLine.cpp implements into a category so that the APIs to hide options can not hide based on the generic category instead of string matching a partial list of argument strings.

This patch is pretty simple and straight forward but it does impact the -help output of all tools using cl::opt. Specifically the options implemented in CommandLine.cpp (help, help-list, help-hidden, help-list-hidden, print-options, print-all-options, version) are all grouped together into an Option category, and these options are never hidden by the cl::HideUnrelatedOptions API.

Reviewers: dexonsmith, chandlerc, majnemer

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D7150

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@227093 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Support/CommandLine.cpp
unittests/Support/CommandLineTest.cpp