// File: tomfunkhouser[P]gaps/pkgs/RNBasics/json.cpp
// Function: Json::StyledWriter::writeArrayValue(Json::Value const&)
void StyledWriter::writeArrayValue(const Value& value) {
  unsigned size = value.size();
  if (size == 0)
    pushValue("[]");
  else {
    bool isArrayMultiLine = isMultineArray(value);
    if (isArrayMultiLine) {
      writeWithIndent("[");
      indent();
      bool hasChildValue = !childValues_.empty();
      unsigned index = 0;
      for (;;) {
        const Value& childValue = value[index];
        writeCommentBeforeValue(childValue);
        if (hasChildValue)
          writeWithIndent(childValues_[index]);
        else {
          writeIndent();
          writeValue(childValue);
        }
        if (++index == size) {
          writeCommentAfterValueOnSameLine(childValue);
          break;
        }
        document_ += ',';
        writeCommentAfterValueOnSameLine(childValue);
      }
      unindent();
      writeWithIndent("]");
    } else // output on a single line
    {
      assert(childValues_.size() == size);
      document_ += "[ ";
      for (unsigned index = 0; index < size; ++index) {
        if (index > 0)
          document_ += ", ";
        document_ += childValues_[index];
      }
      document_ += " ]";
    }
  }
}

// Assembly:
subq $0xc8, %rsp
movq %rdi, 0xc0(%rsp)
movq %rsi, 0xb8(%rsp)
movq 0xc0(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0xb8(%rsp), %rdi
callq 0xeb340
movl %eax, 0xb4(%rsp)
cmpl $0x0, 0xb4(%rsp)
jne 0xf4c79
leaq 0x8f(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x12c30
movq 0x10(%rsp), %rdx
leaq 0x7601c(%rip), %rsi     # 0x16ac10
leaq 0x90(%rsp), %rdi
callq 0x22830
jmp 0xf4c03
movq 0x18(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0xf4b40
jmp 0xf4c17
leaq 0x90(%rsp), %rdi
callq 0x12430
leaq 0x8f(%rsp), %rdi
callq 0x12760
jmp 0xf4f26
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
jmp 0xf4c67
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
leaq 0x90(%rsp), %rdi
callq 0x12430
leaq 0x8f(%rsp), %rdi
callq 0x12760
jmp 0xf4f2e
movq 0x18(%rsp), %rdi
movq 0xb8(%rsp), %rsi
callq 0xf5080
andb $0x1, %al
movb %al, 0x7b(%rsp)
testb $0x1, 0x7b(%rsp)
je 0xf4e97
leaq 0x57(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x12c30
movq 0x8(%rsp), %rdx
leaq 0x72045(%rip), %rsi     # 0x166cfc
leaq 0x58(%rsp), %rdi
callq 0x22830
jmp 0xf4cc3
movq 0x18(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0xf4f40
jmp 0xf4cd4
leaq 0x58(%rsp), %rdi
callq 0x12430
leaq 0x57(%rsp), %rdi
callq 0x12760
movq 0x18(%rsp), %rdi
callq 0xf4f80
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
callq 0xfad40
xorb $-0x1, %al
andb $0x1, %al
movb %al, 0x56(%rsp)
movl $0x0, 0x50(%rsp)
movq 0xb8(%rsp), %rdi
movl 0x50(%rsp), %esi
callq 0xf0020
movq 0x18(%rsp), %rdi
movq %rax, 0x48(%rsp)
movq 0x48(%rsp), %rsi
callq 0xf4000
testb $0x1, 0x56(%rsp)
je 0xf4d9c
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
movl 0x50(%rsp), %eax
movl %eax, %esi
callq 0xf9cf0
movq 0x18(%rsp), %rdi
movq %rax, %rsi
callq 0xf4f40
jmp 0xf4db5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
jmp 0xf4d8d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x12430
leaq 0x57(%rsp), %rdi
callq 0x12760
jmp 0xf4f2e
movq 0x18(%rsp), %rdi
callq 0xf5260
movq 0x18(%rsp), %rdi
movq 0x48(%rsp), %rsi
callq 0xf41b0
movl 0x50(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x50(%rsp)
cmpl 0xb4(%rsp), %eax
jne 0xf4dda
movq 0x18(%rsp), %rdi
movq 0x48(%rsp), %rsi
callq 0xf49b0
jmp 0xf4e01
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
movl $0x2c, %esi
callq 0x12450
movq 0x18(%rsp), %rdi
movq 0x48(%rsp), %rsi
callq 0xf49b0
jmp 0xf4d10
movq 0x18(%rsp), %rdi
callq 0xf5030
leaq 0x27(%rsp), %rdi
movq %rdi, (%rsp)
callq 0x12c30
movq (%rsp), %rdx
leaq 0x71f03(%rip), %rsi     # 0x166d27
leaq 0x28(%rsp), %rdi
callq 0x22830
jmp 0xf4e30
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0xf4f40
jmp 0xf4e41
leaq 0x28(%rsp), %rdi
callq 0x12430
leaq 0x27(%rsp), %rdi
callq 0x12760
jmp 0xf4f24
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
jmp 0xf4e88
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x80(%rsp)
movl %eax, 0x7c(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x12430
leaq 0x27(%rsp), %rdi
callq 0x12760
jmp 0xf4f2e
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
leaq 0x75d6c(%rip), %rsi     # 0x16ac13
callq 0x12670
movl $0x0, 0x20(%rsp)
movl 0x20(%rsp), %eax
cmpl 0xb4(%rsp), %eax
jae 0xf4f0f
cmpl $0x0, 0x20(%rsp)
jbe 0xf4edd
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
leaq 0x75d3e(%rip), %rsi     # 0x16ac16
callq 0x12670
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
movl 0x20(%rsp), %eax
movl %eax, %esi
callq 0xf9cf0
movq 0x18(%rsp), %rdi
movq %rax, %rsi
addq $0x20, %rdi
callq 0x12910
movl 0x20(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x20(%rsp)
jmp 0xf4eb4
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
leaq 0x71e07(%rip), %rsi     # 0x166d26
callq 0x12670
jmp 0xf4f26
addq $0xc8, %rsp
retq
movq 0x80(%rsp), %rdi
callq 0x12c20
nopl (%rax,%rax)