// File: zeeev[P]DASVC/bamtools/src/third_party/jsoncpp/json_value.cpp
// Function: Json::Value::isConvertibleTo(Json::ValueType) const
bool 
Value::isConvertibleTo( ValueType other ) const
{
   switch ( type_ )
   {
   case nullValue:
      return true;
   case intValue:
      return ( other == nullValue  &&  value_.int_ == 0 )
             || other == intValue
             || ( other == uintValue  && value_.int_ >= 0 )
             || other == realValue
             || other == stringValue
             || other == booleanValue;
   case uintValue:
      return ( other == nullValue  &&  value_.uint_ == 0 )
             || ( other == intValue  && value_.uint_ <= (unsigned)maxInt )
             || other == uintValue
             || other == realValue
             || other == stringValue
             || other == booleanValue;
   case realValue:
      return ( other == nullValue  &&  value_.real_ == 0.0 )
             || ( other == intValue  &&  value_.real_ >= minInt  &&  value_.real_ <= maxInt )
             || ( other == uintValue  &&  value_.real_ >= 0  &&  value_.real_ <= maxUInt )
             || other == realValue
             || other == stringValue
             || other == booleanValue;
   case booleanValue:
      return ( other == nullValue  &&  value_.bool_ == false )
             || other == intValue
             || other == uintValue
             || other == realValue
             || other == stringValue
             || other == booleanValue;
   case stringValue:
      return other == stringValue
             || ( other == nullValue  &&  (!value_.string_  ||  value_.string_[0] == 0) );
   case arrayValue:
      return other == arrayValue
             ||  ( other == nullValue  &&  value_.map_->size() == 0 );
   case objectValue:
      return other == objectValue
             ||  ( other == nullValue  &&  value_.map_->size() == 0 );
   default:
      JSON_ASSERT_UNREACHABLE;
   }
   return false; // unreachable;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x10(%rsp)
movzbl 0x8(%rax), %eax
movzwl %ax, %ecx
movq %rcx, 0x18(%rsp)
subw $0x7, %ax
ja 0x1231e0
movq 0x18(%rsp), %rax
leaq 0x11b77(%rip), %rcx     # 0x134a40
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movb $0x1, 0x37(%rsp)
jmp 0x1231e7
cmpl $0x0, 0x24(%rsp)
jne 0x122ef4
movq 0x10(%rsp), %rcx
movb $0x1, %al
cmpq $0x0, (%rcx)
movb %al, 0xf(%rsp)
je 0x122f3f
movb $0x1, %al
cmpl $0x1, 0x24(%rsp)
movb %al, 0xf(%rsp)
je 0x122f3f
cmpl $0x2, 0x24(%rsp)
jne 0x122f19
movq 0x10(%rsp), %rcx
movb $0x1, %al
cmpq $0x0, (%rcx)
movb %al, 0xf(%rsp)
jge 0x122f3f
movb $0x1, %al
cmpl $0x3, 0x24(%rsp)
movb %al, 0xf(%rsp)
je 0x122f3f
movb $0x1, %al
cmpl $0x4, 0x24(%rsp)
movb %al, 0xf(%rsp)
je 0x122f3f
cmpl $0x5, 0x24(%rsp)
sete %al
movb %al, 0xf(%rsp)
movb 0xf(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
cmpl $0x0, 0x24(%rsp)
jne 0x122f66
movq 0x10(%rsp), %rcx
movb $0x1, %al
cmpq $0x0, (%rcx)
movb %al, 0xe(%rsp)
je 0x122fb5
cmpl $0x1, 0x24(%rsp)
jne 0x122f82
movq 0x10(%rsp), %rcx
movb $0x1, %al
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
cmpq %rdx, (%rcx)
movb %al, 0xe(%rsp)
jbe 0x122fb5
movb $0x1, %al
cmpl $0x2, 0x24(%rsp)
movb %al, 0xe(%rsp)
je 0x122fb5
movb $0x1, %al
cmpl $0x3, 0x24(%rsp)
movb %al, 0xe(%rsp)
je 0x122fb5
movb $0x1, %al
cmpl $0x4, 0x24(%rsp)
movb %al, 0xe(%rsp)
je 0x122fb5
cmpl $0x5, 0x24(%rsp)
sete %al
movb %al, 0xe(%rsp)
movb 0xe(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
cmpl $0x0, 0x24(%rsp)
jne 0x122fea
movq 0x10(%rsp), %rax
movsd (%rax), %xmm0
movb $0x1, %al
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
movb %al, 0xd(%rsp)
jne 0x122fea
jp 0x122fea
jmp 0x123079
cmpl $0x1, 0x24(%rsp)
jne 0x123021
movq 0x10(%rsp), %rax
movsd (%rax), %xmm0
movsd 0x11a76(%rip), %xmm1    # 0x134a78
ucomisd %xmm1, %xmm0
jb 0x123021
movq 0x10(%rsp), %rcx
movb $0x1, %al
movsd 0xf231(%rip), %xmm0     # 0x132248
ucomisd (%rcx), %xmm0
movb %al, 0xd(%rsp)
jae 0x123079
cmpl $0x2, 0x24(%rsp)
jne 0x123053
movq 0x10(%rsp), %rax
movsd (%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x123053
movq 0x10(%rsp), %rcx
movb $0x1, %al
movsd 0x11a37(%rip), %xmm0    # 0x134a80
ucomisd (%rcx), %xmm0
movb %al, 0xd(%rsp)
jae 0x123079
movb $0x1, %al
cmpl $0x3, 0x24(%rsp)
movb %al, 0xd(%rsp)
je 0x123079
movb $0x1, %al
cmpl $0x4, 0x24(%rsp)
movb %al, 0xd(%rsp)
je 0x123079
cmpl $0x5, 0x24(%rsp)
sete %al
movb %al, 0xd(%rsp)
movb 0xd(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
cmpl $0x0, 0x24(%rsp)
jne 0x1230a6
movq 0x10(%rsp), %rax
movb (%rax), %al
andb $0x1, %al
movzbl %al, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, 0xc(%rsp)
je 0x1230e6
movb $0x1, %al
cmpl $0x1, 0x24(%rsp)
movb %al, 0xc(%rsp)
je 0x1230e6
movb $0x1, %al
cmpl $0x2, 0x24(%rsp)
movb %al, 0xc(%rsp)
je 0x1230e6
movb $0x1, %al
cmpl $0x3, 0x24(%rsp)
movb %al, 0xc(%rsp)
je 0x1230e6
movb $0x1, %al
cmpl $0x4, 0x24(%rsp)
movb %al, 0xc(%rsp)
je 0x1230e6
cmpl $0x5, 0x24(%rsp)
sete %al
movb %al, 0xc(%rsp)
movb 0xc(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
movb $0x1, %al
cmpl $0x4, 0x24(%rsp)
movb %al, 0xb(%rsp)
je 0x123145
xorl %eax, %eax
cmpl $0x0, 0x24(%rsp)
movb %al, 0xa(%rsp)
jne 0x12313d
movq 0x10(%rsp), %rcx
movb $0x1, %al
cmpq $0x0, (%rcx)
movb %al, 0x9(%rsp)
je 0x123135
movq 0x10(%rsp), %rax
movq (%rax), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
sete %al
movb %al, 0x9(%rsp)
movb 0x9(%rsp), %al
movb %al, 0xa(%rsp)
movb 0xa(%rsp), %al
movb %al, 0xb(%rsp)
movb 0xb(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
movb $0x1, %al
cmpl $0x6, 0x24(%rsp)
movb %al, 0x8(%rsp)
je 0x12318e
xorl %eax, %eax
cmpl $0x0, 0x24(%rsp)
movb %al, 0x7(%rsp)
jne 0x123186
movq 0x10(%rsp), %rax
movq (%rax), %rdi
callq 0x1259d0
cmpq $0x0, %rax
sete %al
movb %al, 0x7(%rsp)
movb 0x7(%rsp), %al
movb %al, 0x8(%rsp)
movb 0x8(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
movb $0x1, %al
cmpl $0x7, 0x24(%rsp)
movb %al, 0x6(%rsp)
je 0x1231d4
xorl %eax, %eax
cmpl $0x0, 0x24(%rsp)
movb %al, 0x5(%rsp)
jne 0x1231cc
movq 0x10(%rsp), %rax
movq (%rax), %rdi
callq 0x1259d0
cmpq $0x0, %rax
sete %al
movb %al, 0x5(%rsp)
movb 0x5(%rsp), %al
movb %al, 0x6(%rsp)
movb 0x6(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0x1231e7
jmp 0x1231e2
movb $0x0, 0x37(%rsp)
movb 0x37(%rsp), %al
andb $0x1, %al
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)