// File: /workspace/github_cpp_makefile_star2_O2/TheStanian[P]Args/main.cpp
// Function: main
int main(int argc, char *argv[]) {
	/* It's as simple as creating an instance of ArgsHandler! */
	ArgsHandler args(argc, argv, true);

	/* Printing all args could be useful for debugging purposes. */
	std::cout << args << std::endl;

	// Checking for flag "flag" (-flag)
	if (args.hasFlag("flag")) {
		std::cout << "We have a flag called flag!" << std::endl;
	}

	/* Checking for a flag's value (-flag=value) */
	if (args.hasFlag("flag")) {
		std::cout << "It even has a value of \"" << args.getFlagValueString("flag") << "\"!" << std::endl;
	}

	/* No need to ensure the flag actually has been set, as you can easily provide a default! */
	if (!args.hasFlag("flag")) {
		std::cout << "There is no flag called flag, but we can still get the default value of \""
				<< args.getFlagValueString("flag", "_defaultValue") << "\"."<< std::endl;
	}
	/*
	 * (I have also provided methods for doubles, ints and bools.
	 *  I decided not to go with templates here, as implementation for every case is different, and templates are messy.)
	 */

	/* You can get the arguments after a specific flag (-flag in this case) like so: */
	std::vector<std::string> argsAfterFlag = args.getFlagArguments("flag");
	std::cout << "arguments after flag \"flag\": ";
	for (std::string &s:argsAfterFlag) {
		std::cout << s << "; ";
	}
	std::cout << std::endl;

	/* In some cases it can be useful to check which flags you've checked for so far.
	 * You can get them as a std::set<std::string> or printed to cout.
	 */
	args.printCheckedFlags();

	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1e8, %rsp            # imm = 0x1E8
movq %rsi, %rdx
movl %edi, %esi
leaq 0x130(%rsp), %rbx
pushq $0x1
popq %rcx
movq %rbx, %rdi
callq 0x2ac0
movq 0x7ba7(%rip), %rdi      # 0x9fd0
movq %rbx, %rsi
callq 0x380c
movq %rax, %rdi
callq 0x20c0
leaq 0x3bc4(%rip), %rsi      # 0x6004
leaq 0x110(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq 0x27fc
leaq 0x130(%rsp), %rdi
leaq 0x110(%rsp), %rsi
callq 0x3032
movl %eax, %ebx
leaq 0x110(%rsp), %rdi
callq 0x20b0
testb %bl, %bl
je 0x2495
movq 0x7b4f(%rip), %rdi      # 0x9fd0
leaq 0x3b81(%rip), %rsi      # 0x6009
callq 0x2170
movq %rax, %rdi
callq 0x20c0
leaq 0x3b68(%rip), %rsi      # 0x6004
leaq 0xf0(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq 0x27fc
leaq 0x130(%rsp), %rdi
leaq 0xf0(%rsp), %rsi
callq 0x3032
movl %eax, %ebx
leaq 0xf0(%rsp), %rdi
callq 0x20b0
testb %bl, %bl
je 0x258c
movq 0x7aef(%rip), %rdi      # 0x9fd0
leaq 0x3b3d(%rip), %rsi      # 0x6025
callq 0x2170
movq %rax, %rbx
leaq 0x3b0d(%rip), %rsi      # 0x6004
leaq 0xd0(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x27fc
leaq 0x3c1b(%rip), %rsi      # 0x612b
leaq 0xb0(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x27fc
leaq 0x10(%rsp), %rdi
leaq 0x130(%rsp), %rsi
leaq 0xd0(%rsp), %rdx
leaq 0xb0(%rsp), %rcx
callq 0x3072
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x2160
leaq 0x3ae6(%rip), %rsi      # 0x603e
movq %rax, %rdi
callq 0x2170
movq %rax, %rdi
callq 0x20c0
leaq 0x10(%rsp), %rdi
callq 0x20b0
leaq 0xb0(%rsp), %rdi
callq 0x20b0
leaq 0xd0(%rsp), %rdi
callq 0x20b0
leaq 0x3a71(%rip), %rsi      # 0x6004
leaq 0x90(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq 0x27fc
leaq 0x130(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x3032
movl %eax, %ebx
leaq 0x90(%rsp), %rdi
callq 0x20b0
testb %bl, %bl
jne 0x2671
movq 0x79f8(%rip), %rdi      # 0x9fd0
leaq 0x3a62(%rip), %rsi      # 0x6041
callq 0x2170
movq %rax, %rbx
leaq 0x3a16(%rip), %rsi      # 0x6004
leaq 0x70(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x27fc
leaq 0x3a87(%rip), %rsi      # 0x608b
leaq 0x50(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x27fc
leaq 0x10(%rsp), %rdi
leaq 0x130(%rsp), %rsi
leaq 0x70(%rsp), %rdx
leaq 0x50(%rsp), %rcx
callq 0x3072
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x2160
leaq 0x3a56(%rip), %rsi      # 0x6099
movq %rax, %rdi
callq 0x2170
movq %rax, %rdi
callq 0x20c0
leaq 0x10(%rsp), %rdi
callq 0x20b0
leaq 0x50(%rsp), %rdi
callq 0x20b0
leaq 0x70(%rsp), %rdi
callq 0x20b0
leaq 0x398c(%rip), %rsi      # 0x6004
leaq 0x30(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0x27fc
leaq 0x10(%rsp), %rdi
leaq 0x130(%rsp), %rsi
leaq 0x30(%rsp), %rdx
callq 0x3344
leaq 0x30(%rsp), %rdi
callq 0x20b0
movq 0x7921(%rip), %rdi      # 0x9fd0
leaq 0x39e6(%rip), %rsi      # 0x609c
callq 0x2170
movq 0x10(%rsp), %rbx
movq 0x18(%rsp), %r12
movq 0x7904(%rip), %r14      # 0x9fd0
leaq 0x39e7(%rip), %r15      # 0x60ba
cmpq %r12, %rbx
je 0x26f4
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2160
movq %rax, %rdi
movq %r15, %rsi
callq 0x2170
addq $0x20, %rbx
jmp 0x26d3
movq 0x78d5(%rip), %rdi      # 0x9fd0
callq 0x20c0
leaq 0x130(%rsp), %rdi
callq 0x373a
leaq 0x10(%rsp), %rdi
callq 0x2838
leaq 0x130(%rsp), %rdi
callq 0x285a
xorl %eax, %eax
addq $0x1e8, %rsp            # imm = 0x1E8
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
jmp 0x2799
movq %rax, %rbx
jmp 0x27a3
jmp 0x27d5
movq %rax, %rbx
jmp 0x27b7
movq %rax, %rbx
jmp 0x27c4
jmp 0x27d5
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
jmp 0x27cc
jmp 0x27d5
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
jmp 0x27cc
jmp 0x27d5
movq %rax, %rbx
leaq 0xf0(%rsp), %rdi
jmp 0x27cc
jmp 0x27d5
movq %rax, %rbx
leaq 0x110(%rsp), %rdi
jmp 0x27cc
jmp 0x27d5
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x20b0
leaq 0x50(%rsp), %rdi
callq 0x20b0
leaq 0x70(%rsp), %rdi
jmp 0x27cc
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x20b0
leaq 0xb0(%rsp), %rdi
callq 0x20b0
leaq 0xd0(%rsp), %rdi
callq 0x20b0
jmp 0x27e7
jmp 0x27da
movq %rax, %rbx
jmp 0x27e7
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x2838
leaq 0x130(%rsp), %rdi
callq 0x285a
movq %rbx, %rdi
callq 0x2260