// File: /workspace/github_cpp_makefile_star2_O2/halfflat[P]tinyopt/test/googletest/googletest/src/gtest.cc
// Function: testing::internal::JsonUnitTestResultPrinter::OutputJsonTestResult(std::ostream*, testing::TestResult const&)
void JsonUnitTestResultPrinter::OutputJsonTestResult(::std::ostream* stream,
                                                     const TestResult& result) {
  const std::string kIndent = Indent(10);

  int failures = 0;
  for (int i = 0; i < result.total_part_count(); ++i) {
    const TestPartResult& part = result.GetTestPartResult(i);
    if (part.failed()) {
      *stream << ",\n";
      if (++failures == 1) {
        *stream << kIndent << "\""
                << "failures"
                << "\": [\n";
      }
      const std::string location =
          internal::FormatCompilerIndependentFileLocation(part.file_name(),
                                                          part.line_number());
      const std::string message = EscapeJson(location + "\n" + part.message());
      *stream << kIndent << "  {\n"
              << kIndent << "    \"failure\": \"" << message << "\",\n"
              << kIndent << "    \"type\": \"\"\n"
              << kIndent << "  }";
    }
  }

  if (failures > 0) *stream << "\n" << kIndent << "]";
  *stream << "\n" << Indent(8) << "}";
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %rbx
subq $0xb0, %rsp
movq %rsi, %r14
movq %rdi, (%rsp)
leaq 0x10(%rsp), %rdi
pushq $0xa
popq %rsi
callq 0x46dae
xorl %ebp, %ebp
leaq 0x70(%rsp), %rbx
xorl %r15d, %r15d
movq 0x40(%r14), %rax
subq 0x38(%r14), %rax
cqto
pushq $0x70
popq %rcx
idivq %rcx
cmpl %eax, %ebp
jge 0x47564
movq %r14, %rdi
movl %ebp, %esi
callq 0x3fadc
movq %rax, %r13
movl (%rax), %eax
decl %eax
cmpl $0x1, %eax
ja 0x4755d
movq (%rsp), %rdi
leaq 0x152ad(%rip), %rsi     # 0x5c6b3
callq 0xd550
testl %r15d, %r15d
jne 0x4744b
movq (%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x15288(%rip), %rsi     # 0x5c6b0
callq 0xd550
movq %rax, %rdi
leaq 0x15b04(%rip), %rsi     # 0x5cf3b
callq 0xd550
movq %rax, %rdi
leaq 0x15229(%rip), %rsi     # 0x5c66f
callq 0xd550
movl %r15d, 0xc(%rsp)
movq 0x10(%r13), %rsi
testq %rsi, %rsi
je 0x4745d
movq 0x8(%r13), %rsi
movl 0x28(%r13), %edx
leaq 0x30(%rsp), %r15
movq %r15, %rdi
callq 0x39d05
movq %rbx, %rdi
movq %r15, %rsi
leaq 0x11cde(%rip), %rdx     # 0x59159
callq 0x1dd28
movq 0x50(%r13), %rdx
leaq 0x90(%rsp), %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0x4c05c
leaq 0x50(%rsp), %rdi
movq %r15, %rsi
callq 0x45ee4
movq %r15, %rdi
callq 0xdbe8
movq %rbx, %rdi
callq 0xdbe8
movq (%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x151d0(%rip), %rsi     # 0x5c69c
callq 0xd550
movq %rax, %rdi
leaq 0x10(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x151b9(%rip), %rsi     # 0x5c6a1
callq 0xd550
movq %rax, %rdi
leaq 0x50(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x151ae(%rip), %rsi     # 0x5c6b2
callq 0xd550
movq %rax, %rdi
leaq 0x10(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x15196(%rip), %rsi     # 0x5c6b6
callq 0xd550
movq %rax, %rdi
leaq 0x10(%rsp), %rsi
callq 0xd4e0
movq %rax, %rdi
leaq 0x1518a(%rip), %rsi     # 0x5c6c6
callq 0xd550
movl 0xc(%rsp), %r15d
incl %r15d
leaq 0x50(%rsp), %rdi
callq 0xdbe8
leaq 0x30(%rsp), %rdi
callq 0xdbe8
incl %ebp
jmp 0x473c9
testl %r15d, %r15d
jle 0x47595
leaq 0x11be9(%rip), %rsi     # 0x59159
movq (%rsp), %rdi
callq 0xd550
leaq 0x10(%rsp), %rsi
movq %rax, %rdi
callq 0xd4e0
leaq 0x13ec3(%rip), %rsi     # 0x5b450
movq %rax, %rdi
callq 0xd550
leaq 0x11bbd(%rip), %rsi     # 0x59159
movq (%rsp), %rdi
callq 0xd550
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
pushq $0x8
popq %rsi
callq 0x46dae
leaq 0x30(%rsp), %rsi
movq %rbx, %rdi
callq 0xd4e0
leaq 0x150ff(%rip), %rsi     # 0x5c6c8
movq %rax, %rdi
callq 0xd550
leaq 0x30(%rsp), %rdi
callq 0xdbe8
leaq 0x10(%rsp), %rdi
callq 0xdbe8
addq $0xb0, %rsp
popq %rbx
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4761e
jmp 0x475fb
jmp 0x4761e
movq %rax, %rbx
jmp 0x47630
movq %rax, %rbx
jmp 0x47617
jmp 0x4761e
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0xdbe8
leaq 0x70(%rsp), %rdi
jmp 0x4762b
movq %rax, %rbx
jmp 0x4763a
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0xdbe8
leaq 0x30(%rsp), %rdi
callq 0xdbe8
leaq 0x10(%rsp), %rdi
callq 0xdbe8
movq %rbx, %rdi
callq 0xdaa0