LLVM 20.0.0git
|
#include "llvm/Support/CommandLine.h"
Classes | |
class | GenericOptionInfo |
Public Member Functions | |
generic_parser_base (Option &O) | |
virtual | ~generic_parser_base ()=default |
virtual unsigned | getNumOptions () const =0 |
virtual StringRef | getOption (unsigned N) const =0 |
virtual StringRef | getDescription (unsigned N) const =0 |
virtual size_t | getOptionWidth (const Option &O) const |
virtual const GenericOptionValue & | getOptionValue (unsigned N) const =0 |
virtual void | printOptionInfo (const Option &O, size_t GlobalWidth) const |
void | printGenericOptionDiff (const Option &O, const GenericOptionValue &V, const GenericOptionValue &Default, size_t GlobalWidth) const |
template<class AnyOptionValue > | |
void | printOptionDiff (const Option &O, const AnyOptionValue &V, const AnyOptionValue &Default, size_t GlobalWidth) const |
void | initialize () |
void | getExtraOptionNames (SmallVectorImpl< StringRef > &OptionNames) |
enum ValueExpected | getValueExpectedFlagDefault () const |
unsigned | findOption (StringRef Name) |
Protected Attributes | |
Option & | Owner |
Definition at line 727 of file CommandLine.h.
|
inline |
Definition at line 738 of file CommandLine.h.
|
virtualdefault |
Definition at line 2069 of file CommandLine.cpp.
References getNumOptions(), getOption(), and Name.
Referenced by llvm::cl::parser< DataType >::addLiteralOption(), llvm::PassNameParser::passRegistered(), and llvm::cl::parser< DataType >::removeLiteralOption().
Implemented in llvm::cl::parser< DataType >, llvm::cl::parser< const PassInfo * >, llvm::cl::parser< RegistryClass::FunctionPassCtor >, llvm::cl::parser< std::set< SPIRV::Extension::Extension > >, and llvm::cl::parser< std::optional< uint64_t > >.
Referenced by getOptionWidth(), and printOptionInfo().
|
inline |
Definition at line 781 of file CommandLine.h.
References getNumOptions(), getOption(), llvm::cl::Option::hasArgStr(), Owner, and llvm::SmallVectorTemplateBase< T, bool >::push_back().
|
pure virtual |
Implemented in llvm::cl::parser< DataType >, llvm::cl::parser< const PassInfo * >, llvm::cl::parser< RegistryClass::FunctionPassCtor >, llvm::cl::parser< std::set< SPIRV::Extension::Extension > >, and llvm::cl::parser< std::optional< uint64_t > >.
Referenced by findOption(), getExtraOptionNames(), getOptionWidth(), printGenericOptionDiff(), and printOptionInfo().
Implemented in llvm::cl::parser< DataType >, llvm::cl::parser< const PassInfo * >, llvm::cl::parser< RegistryClass::FunctionPassCtor >, llvm::cl::parser< std::set< SPIRV::Extension::Extension > >, and llvm::cl::parser< std::optional< uint64_t > >.
Referenced by findOption(), getExtraOptionNames(), getOptionWidth(), printGenericOptionDiff(), and printOptionInfo().
|
pure virtual |
Definition at line 2093 of file CommandLine.cpp.
References argPlusPrefixesSize(), EmptyOption, EqValue, getDescription(), getNumOptions(), getOption(), getOptionPrefixesSize(), Name, llvm::XCOFF::NameSize, shouldPrintOption(), llvm::StringRef::size(), llvm::size(), and Size.
|
inline |
Definition at line 790 of file CommandLine.h.
References llvm::cl::Option::hasArgStr(), Owner, llvm::cl::ValueDisallowed, and llvm::cl::ValueRequired.
|
inline |
Definition at line 779 of file CommandLine.h.
Referenced by llvm::RegisterPassParser< RegistryClass >::initialize(), and llvm::PassNameParser::initialize().
void generic_parser_base::printGenericOptionDiff | ( | const Option & | O, |
const GenericOptionValue & | V, | ||
const GenericOptionValue & | Default, | ||
size_t | GlobalWidth | ||
) | const |
Definition at line 2169 of file CommandLine.cpp.
References llvm::Default, getNumOptions(), getOption(), getOptionValue(), llvm::raw_ostream::indent(), MaxOptWidth, llvm::outs(), and llvm::StringRef::size().
Referenced by printOptionDiff().
|
inline |
Definition at line 773 of file CommandLine.h.
References llvm::Default, and printGenericOptionDiff().
Reimplemented in llvm::PassNameParser.
Definition at line 2116 of file CommandLine.cpp.
References argPlusPrefixesSize(), assert(), llvm::StringRef::empty(), EmptyOption, EqValue, getDescription(), getNumOptions(), getOption(), getOptionPrefixesSize(), OptionPrefix, llvm::outs(), llvm::cl::Option::printEnumValHelpStr(), llvm::cl::Option::printHelpStr(), shouldPrintOption(), llvm::StringRef::size(), and llvm::cl::ValueOptional.
Referenced by llvm::PassNameParser::printOptionInfo().
|
protected |
Definition at line 814 of file CommandLine.h.
Referenced by llvm::cl::parser< DataType >::addLiteralOption(), getExtraOptionNames(), getValueExpectedFlagDefault(), and llvm::cl::parser< DataType >::parse().