// File: /workspace/github_cpp_makefile_star2_O2/Falldog[P]dcinja/src/include/nlohmann/json.hpp
// Function: nlohmann::detail::iter_impl<nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>> nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::erase<nlohmann::detail::iter_impl<nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>>, 0>(nlohmann::detail::iter_impl<nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>>)
IteratorType erase(IteratorType pos)
    {
        // make sure iterator fits the current value
        if (JSON_HEDLEY_UNLIKELY(this != pos.m_object))
        {
            JSON_THROW(invalid_iterator::create(202, "iterator does not fit current value"));
        }

        IteratorType result = end();

        switch (m_type)
        {
            case value_t::boolean:
            case value_t::number_float:
            case value_t::number_integer:
            case value_t::number_unsigned:
            case value_t::string:
            case value_t::binary:
            {
                if (JSON_HEDLEY_UNLIKELY(!pos.m_it.primitive_iterator.is_begin()))
                {
                    JSON_THROW(invalid_iterator::create(205, "iterator out of range"));
                }

                if (is_string())
                {
                    AllocatorType<string_t> alloc;
                    std::allocator_traits<decltype(alloc)>::destroy(alloc, m_value.string);
                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_value.string, 1);
                    m_value.string = nullptr;
                }
                else if (is_binary())
                {
                    AllocatorType<binary_t> alloc;
                    std::allocator_traits<decltype(alloc)>::destroy(alloc, m_value.binary);
                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_value.binary, 1);
                    m_value.binary = nullptr;
                }

                m_type = value_t::null;
                assert_invariant();
                break;
            }

            case value_t::object:
            {
                result.m_it.object_iterator = m_value.object->erase(pos.m_it.object_iterator);
                break;
            }

            case value_t::array:
            {
                result.m_it.array_iterator = m_value.array->erase(pos.m_it.array_iterator);
                break;
            }

            default:
                JSON_THROW(type_error::create(307, "cannot use erase() with " + std::string(type_name())));
        }

        return result;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
cmpq %rsi, (%rdx)
jne 0x1f763
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
callq 0xcf3a
movzbl (%r14), %eax
leal -0x3(%rax), %ecx
cmpl $0x6, %ecx
jae 0x1f6f9
cmpq $0x0, 0x18(%r15)
jne 0x1f7b6
cmpl $0x8, %eax
je 0x1f71a
cmpl $0x3, %eax
jne 0x1f736
leaq 0x8(%r14), %r15
movq 0x8(%r14), %rdi
callq 0x9898
jmp 0x1f727
cmpl $0x1, %eax
je 0x1f750
cmpl $0x2, %eax
jne 0x1f806
movq 0x8(%r14), %rdi
movq 0x10(%r15), %rsi
callq 0x2037c
movq %rax, 0x10(%rbx)
jmp 0x1f742
leaq 0x8(%r14), %r15
movq 0x8(%r14), %rdi
callq 0x1fff2
movq (%r15), %rdi
pushq $0x20
popq %rsi
callq 0x93e0
andq $0x0, (%r15)
movb $0x0, (%r14)
movq %r14, %rdi
callq 0x1d1fc
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x8(%r14), %rdi
movq 0x8(%r15), %rsi
callq 0x20458
movq %rax, 0x8(%rbx)
jmp 0x1f742
pushq $0x20
popq %rdi
callq 0x9200
movq %rax, %rbx
leaq 0x28e23(%rip), %rsi     # 0x48598
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0xc0a4
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0xca, %esi
callq 0x2006c
xorl %ebp, %ebp
leaq 0x517de(%rip), %rsi     # 0x70f80
leaq 0x22ad(%rip), %rdx      # 0x21a56
movq %rbx, %rdi
callq 0x9760
jmp 0x1f86e
pushq $0x20
popq %rdi
callq 0x9200
movq %rax, %rbx
leaq 0x28df4(%rip), %rsi     # 0x485bc
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0xc0a4
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0xcd, %esi
callq 0x2006c
xorl %ebp, %ebp
leaq 0x5178b(%rip), %rsi     # 0x70f80
leaq 0x225a(%rip), %rdx      # 0x21a56
movq %rbx, %rdi
callq 0x9760
jmp 0x1f86e
pushq $0x20
popq %rdi
callq 0x9200
movq %rax, %rbx
movq %r14, %rdi
callq 0x20438
leaq 0x28(%rsp), %rdi
leaq 0x7(%rsp), %rdx
movq %rax, %rsi
callq 0xc0a4
leaq 0x28da0(%rip), %rsi     # 0x485d2
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x17df0
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0x133, %esi            # imm = 0x133
callq 0x20382
xorl %ebp, %ebp
leaq 0x51789(%rip), %rsi     # 0x70fe8
leaq 0x21f0(%rip), %rdx      # 0x21a56
movq %rbx, %rdi
callq 0x9760
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x9898
jmp 0x1f883
movq %rax, %r14
movb $0x1, %bpl
leaq 0x28(%rsp), %rdi
jmp 0x1f898
jmp 0x1f8a4
jmp 0x1f890
jmp 0x1f8a4
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x9898
testb %bpl, %bpl
jne 0x1f8a7
jmp 0x1f8af
movq %rax, %r14
movq %rbx, %rdi
callq 0x9320
movq %r14, %rdi
callq 0x97a0
nop