// File: RegulusImpact[P]sadboy/include/jsoncpp.cpp
// Function: Json::Reader::parse(char const*, char const*, Json::Value&, bool)
bool Reader::parse(const char* beginDoc,
                   const char* endDoc,
                   Value& root,
                   bool collectComments) {
  if (!features_.allowComments_) {
    collectComments = false;
  }

  begin_ = beginDoc;
  end_ = endDoc;
  collectComments_ = collectComments;
  current_ = begin_;
  lastValueEnd_ = 0;
  lastValue_ = 0;
  commentsBefore_.clear();
  errors_.clear();
  while (!nodes_.empty())
    nodes_.pop();
  nodes_.push(&root);

  bool successful = readValue();
  Token token;
  skipCommentTokens(token);
  if (collectComments_ && !commentsBefore_.empty())
    root.setComment(commentsBefore_, commentAfter);
  if (features_.strictRoot_) {
    if (!root.isArray() && !root.isObject()) {
      // Set error location to start of doc, ideally should be first token found
      // in doc
      token.type_ = tokenError;
      token.start_ = beginDoc;
      token.end_ = endDoc;
      addError(
          "A valid JSON document must be either an array or an object value.",
          token);
      return false;
    }
  }
  return successful;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movb %r8b, %al
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
andb $0x1, %al
movb %al, -0x29(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x98(%rbp)
testb $0x1, 0x108(%rax)
jne 0x5f7b
movb $0x0, -0x29(%rbp)
movq -0x98(%rbp), %rdi
movq -0x18(%rbp), %rax
movq %rax, 0xc0(%rdi)
movq -0x20(%rbp), %rax
movq %rax, 0xc8(%rdi)
movb -0x29(%rbp), %al
andb $0x1, %al
movb %al, 0x10c(%rdi)
movq 0xc0(%rdi), %rax
movq %rax, 0xd0(%rdi)
movq $0x0, 0xd8(%rdi)
movq $0x0, 0xe0(%rdi)
addq $0xe8, %rdi
callq 0x5610
movq -0x98(%rbp), %rdi
addq $0x50, %rdi
callq 0x1e410
movq -0x98(%rbp), %rdi
callq 0x1e450
xorb $-0x1, %al
testb $0x1, %al
jne 0x5ff7
jmp 0x6005
movq -0x98(%rbp), %rdi
callq 0x1e470
jmp 0x5fe3
movq -0x98(%rbp), %rdi
movq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
leaq -0x38(%rbp), %rsi
callq 0x1e490
movq -0x98(%rbp), %rdi
callq 0x6260
movq -0x98(%rbp), %rdi
andb $0x1, %al
movb %al, -0x39(%rbp)
leaq -0x58(%rbp), %rsi
callq 0x6940
movq -0x98(%rbp), %rax
testb $0x1, 0x10c(%rax)
je 0x6081
movq -0x98(%rbp), %rdi
addq $0xe8, %rdi
callq 0x5740
testb $0x1, %al
jne 0x6081
movq -0x98(%rbp), %rsi
movq -0x28(%rbp), %rdi
addq $0xe8, %rsi
movl $0x2, %edx
callq 0x6990
movq -0x98(%rbp), %rax
testb $0x1, 0x109(%rax)
je 0x6165
movq -0x28(%rbp), %rdi
callq 0x69e0
testb $0x1, %al
jne 0x6163
movq -0x28(%rbp), %rdi
callq 0x6a10
testb $0x1, %al
jne 0x6163
movl $0xd, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x48(%rbp)
leaq -0x79(%rbp), %rdi
movq %rdi, -0xa0(%rbp)
callq 0x5790
movq -0xa0(%rbp), %rdx
leaq 0x31b80(%rip), %rsi     # 0x37c6c
leaq -0x78(%rbp), %rdi
callq 0x5650
jmp 0x60f7
movq -0x98(%rbp), %rdi
xorl %eax, %eax
movl %eax, %ecx
leaq -0x78(%rbp), %rsi
leaq -0x58(%rbp), %rdx
callq 0x6a40
jmp 0x6111
leaq -0x78(%rbp), %rdi
callq 0x52c0
leaq -0x79(%rbp), %rdi
callq 0x54f0
movb $0x0, -0x1(%rbp)
jmp 0x616d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0x6158
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0x78(%rbp), %rdi
callq 0x52c0
leaq -0x79(%rbp), %rdi
callq 0x54f0
jmp 0x617b
jmp 0x6165
movb -0x39(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0xa0, %rsp
popq %rbp
retq
movq -0x88(%rbp), %rdi
callq 0x5780
nopw (%rax,%rax)