MCPcopy Create free account
hub / github.com/CodingGay/BlackDex / Args

Class Args

Bcore/src/main/cpp/Dobby/tests/catch.hpp:5400–5415  ·  view source on GitHub ↗

Transport for raw args (copied from main args, or supplied via init list for testing)

Source from the content-addressed store, hash-verified

5398
5399// Transport for raw args (copied from main args, or supplied via init list for testing)
5400class Args {
5401 friend TokenStream;
5402 std::string m_exeName;
5403 std::vector<std::string> m_args;
5404
5405public:
5406 Args(int argc, char const *const *argv) : m_exeName(argv[0]), m_args(argv + 1, argv + argc) {
5407 }
5408
5409 Args(std::initializer_list<std::string> args) : m_exeName(*args.begin()), m_args(args.begin() + 1, args.end()) {
5410 }
5411
5412 auto exeName() const -> std::string {
5413 return m_exeName;
5414 }
5415};
5416
5417// Wraps a token coming from a token stream. These may not directly correspond to strings as a single string
5418// may encode an option + its argument if the : or = form is used

Callers 1

applyCommandLineMethod · 0.85

Calls

no outgoing calls

Tested by 1

applyCommandLineMethod · 0.68