// File: /workspace/github_cpp_makefile_star2_O1/interimadd[P]M5Stack-PixelArt/test/lib/googletest/googletest/src/gtest.cc
// Function: void testing::internal::ParseGoogleTestFlagsOnlyImpl<char>(int*, char**)
void ParseGoogleTestFlagsOnlyImpl(int* argc, CharType** argv) {
  for (int i = 1; i < *argc; i++) {
    const std::string arg_string = StreamableToString(argv[i]);
    const char* const arg = arg_string.c_str();

    using internal::ParseBoolFlag;
    using internal::ParseInt32Flag;
    using internal::ParseStringFlag;

    bool remove_flag = false;
    if (ParseGoogleTestFlag(arg)) {
      remove_flag = true;
#if GTEST_USE_OWN_FLAGFILE_FLAG_
    } else if (ParseStringFlag(arg, kFlagfileFlag, &GTEST_FLAG(flagfile))) {
      LoadFlagsFromFile(GTEST_FLAG(flagfile));
      remove_flag = true;
#endif  // GTEST_USE_OWN_FLAGFILE_FLAG_
    } else if (arg_string == "--help" || arg_string == "-h" ||
               arg_string == "-?" || arg_string == "/?" ||
               HasGoogleTestFlagPrefix(arg)) {
      // Both help flag and unrecognized Google Test flags (excluding
      // internal ones) trigger help display.
      g_help_flag = true;
    }

    if (remove_flag) {
      // Shift the remainder of the argv list left by one.  Note
      // that argv has (*argc + 1) elements, the last one always being
      // NULL.  The following loop moves the trailing NULL element as
      // well.
      for (int j = i; j != *argc; j++) {
        argv[j] = argv[j + 1];
      }

      // Decrements the argument count.
      (*argc)--;

      // We also need to decrement the iterator as we just removed
      // an element.
      i--;
    }
  }

  if (g_help_flag) {
    // We print the help here instead of in RUN_ALL_TESTS(), as the
    // latter may not be called at all if the user is using Google
    // Test with another testing framework.
    PrintColorEncoded(kColorEncodedHelpMessage);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
cmpl $0x2, (%rdi)
jl 0x42b9d
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x8(%rsi), %rax
movq %rax, (%rsp)
movl $0x1, %r13d
leaq 0x8(%rsp), %r15
movslq %r13d, %r12
leaq (%rbx,%r12,8), %rsi
movq %r15, %rdi
callq 0x489a3
movq 0x8(%rsp), %rbp
movq %rbp, %rdi
callq 0x36a6b
testb %al, %al
jne 0x42ae8
movq %rbp, %rdi
leaq 0x7c85(%rip), %rsi      # 0x4a751
leaq 0x1dc6d(%rip), %rdx     # 0x60740
callq 0x36a29
testb %al, %al
je 0x42b16
leaq 0x1dc5d(%rip), %rdi     # 0x60740
callq 0x36c53
movl (%r14), %eax
movl %eax, %ecx
subl %r13d, %ecx
je 0x42b0c
movq (%rsp), %rdx
leaq (%rdx,%r12,8), %rdx
xorl %esi, %esi
movq (%rdx,%rsi,8), %rdi
movq %rdi, -0x8(%rdx,%rsi,8)
incq %rsi
cmpl %esi, %ecx
jne 0x42afc
decl %eax
movl %eax, (%r14)
decl %r13d
jmp 0x42b75
movq %r15, %rdi
leaq 0xa8ac(%rip), %rsi      # 0x4d3cc
callq 0x1d140
testl %eax, %eax
je 0x42b6e
movq %r15, %rdi
leaq 0xa8a0(%rip), %rsi      # 0x4d3d3
callq 0x1d140
testl %eax, %eax
je 0x42b6e
movq %r15, %rdi
leaq 0xa890(%rip), %rsi      # 0x4d3d6
callq 0x1d140
testl %eax, %eax
je 0x42b6e
movq %r15, %rdi
leaq 0xa880(%rip), %rsi      # 0x4d3d9
callq 0x1d140
testl %eax, %eax
je 0x42b6e
movq %rbp, %rdi
callq 0x3fa2a
testb %al, %al
je 0x42b75
movb $0x1, 0x1db1c(%rip)     # 0x60691
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x42b91
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1d460
incl %r13d
cmpl (%r14), %r13d
jl 0x42aa2
cmpb $0x0, 0x1daed(%rip)     # 0x60691
je 0x42bab
callq 0x3faa6
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x42bd9
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1d460
movq %rbx, %rdi
callq 0x1d900