// File: zeeev[P]DASVC/bamtools/src/third_party/jsoncpp/json_value.cpp
// Function: Json::Value::Value(Json::Value const&)
Value::Value( const Value &other )
   : type_( other.type_ )
   , comments_( 0 )
# ifdef JSON_VALUE_USE_INTERNAL_MAP
   , itemIsUsed_( 0 )
#endif
{
   switch ( type_ )
   {
   case nullValue:
   case intValue:
   case uintValue:
   case realValue:
   case booleanValue:
      value_ = other.value_;
      break;
   case stringValue:
      if ( other.value_.string_ )
      {
         value_.string_ = duplicateStringValue( other.value_.string_ );
         allocated_ = true;
      }
      else
         value_.string_ = 0;
      break;
#ifndef JSON_VALUE_USE_INTERNAL_MAP
   case arrayValue:
   case objectValue:
      value_.map_ = new ObjectValues( *other.value_.map_ );
      break;
#else
   case arrayValue:
      value_.array_ = arrayAllocator()->newArrayCopy( *other.value_.array_ );
      break;
   case objectValue:
      value_.map_ = mapAllocator()->newMapCopy( *other.value_.map_ );
      break;
#endif
   default:
      JSON_ASSERT_UNREACHABLE;
   }
   if ( other.comments_ )
   {
      comments_ = new CommentInfo[numberOfCommentPlacement];
      for ( int comment =0; comment < numberOfCommentPlacement; ++comment )
      {
         const CommentInfo &otherComment = other.comments_[comment];
         if ( otherComment.comment_ )
            comments_[comment].setComment( otherComment.comment_ );
      }
   }
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x70(%rsp)
movq %rsi, 0x68(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x68(%rsp), %rcx
movb 0x8(%rcx), %cl
movb %cl, 0x8(%rax)
movq $0x0, 0x10(%rax)
movzbl 0x8(%rax), %eax
movzwl %ax, %ecx
movl %ecx, 0x4c(%rsp)
subw $0x4, %ax
jb 0x121745
jmp 0x12171e
movl 0x4c(%rsp), %eax
subl $0x4, %eax
je 0x12175a
jmp 0x121729
movl 0x4c(%rsp), %eax
subl $0x5, %eax
je 0x121745
jmp 0x121734
movl 0x4c(%rsp), %eax
addl $-0x6, %eax
subl $0x2, %eax
jb 0x1217a4
jmp 0x1217f4
movq 0x40(%rsp), %rax
movq 0x68(%rsp), %rcx
movq (%rcx), %rcx
movq %rcx, (%rax)
jmp 0x1217f6
movq 0x68(%rsp), %rax
cmpq $0x0, (%rax)
je 0x121796
movq 0x68(%rsp), %rax
movq (%rax), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x120f70
movq %rax, %rcx
movq 0x40(%rsp), %rax
movq %rcx, (%rax)
movw 0x8(%rax), %cx
andw $0xfeff, %cx            # imm = 0xFEFF
orw $0x100, %cx             # imm = 0x100
movw %cx, 0x8(%rax)
jmp 0x1217a2
movq 0x40(%rsp), %rax
movq $0x0, (%rax)
jmp 0x1217f6
movl $0x30, %edi
callq 0x86720
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x38(%rsp)
movq 0x68(%rsp), %rax
movq (%rax), %rsi
callq 0x125950
jmp 0x1217c8
movq 0x40(%rsp), %rax
movq 0x38(%rsp), %rcx
movq %rcx, (%rax)
jmp 0x1217f6
movq 0x38(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
callq 0x866a0
jmp 0x121935
jmp 0x1217f6
movq 0x68(%rsp), %rax
cmpq $0x0, 0x10(%rax)
je 0x121930
movl $0x20, %edi
callq 0x86040
movq %rax, 0x18(%rsp)
movq $0x3, (%rax)
addq $0x8, %rax
movq %rax, 0x20(%rsp)
movq %rax, %rcx
addq $0x18, %rcx
movq %rcx, 0x28(%rsp)
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x120dc0
jmp 0x121847
movq 0x28(%rsp), %rcx
movq 0x10(%rsp), %rax
addq $0x8, %rax
cmpq %rcx, %rax
movq %rax, 0x30(%rsp)
jne 0x121836
movq 0x40(%rsp), %rax
movq 0x20(%rsp), %rcx
movq %rcx, 0x10(%rax)
movl $0x0, 0x58(%rsp)
cmpl $0x3, 0x58(%rsp)
jge 0x12192e
movq 0x68(%rsp), %rax
movq 0x10(%rax), %rax
movslq 0x58(%rsp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x50(%rsp)
movq 0x50(%rsp), %rax
cmpq $0x0, (%rax)
je 0x12191c
movq 0x40(%rsp), %rax
movq 0x10(%rax), %rdi
movslq 0x58(%rsp), %rax
shlq $0x3, %rax
addq %rax, %rdi
movq 0x50(%rsp), %rax
movq (%rax), %rsi
callq 0x120e30
jmp 0x12191c
movq 0x20(%rsp), %rcx
movq %rax, %rsi
movq 0x10(%rsp), %rax
movq %rsi, 0x60(%rsp)
movl %edx, 0x5c(%rsp)
cmpq %rax, %rcx
movq %rax, 0x8(%rsp)
je 0x121910
movq 0x8(%rsp), %rdi
addq $-0x8, %rdi
movq %rdi, (%rsp)
callq 0x120de0
jmp 0x1218fd
movq (%rsp), %rax
movq 0x20(%rsp), %rcx
cmpq %rcx, %rax
movq %rax, 0x8(%rsp)
jne 0x1218e9
movq 0x18(%rsp), %rdi
callq 0x86930
jmp 0x121935
jmp 0x12191e
movl 0x58(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x58(%rsp)
jmp 0x121875
jmp 0x121930
addq $0x78, %rsp
retq
movq 0x60(%rsp), %rdi
callq 0x86d80
movq %rax, %rdi
callq 0x91290
nopw (%rax,%rax)