// File: /workspace/github_cpp_makefile_star2_O1/Konano[P]UselessDatabase/./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>> 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>::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>>, 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>>)
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:
            {
                if (JSON_HEDLEY_UNLIKELY(not 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;
                }

                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 0x142bf
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
callq 0x14062
movb (%r14), %al
movzbl %al, %ecx
leal -0x3(%rcx), %edx
cmpl $0x5, %edx
jae 0x1428b
cmpq $0x0, 0x18(%r15)
jne 0x1431f
cmpb $0x3, %al
jne 0x14271
movq 0x8(%r14), %rax
movq (%rax), %rdi
addq $0x10, %rax
cmpq %rax, %rdi
je 0x1425b
movq (%rax), %rsi
incq %rsi
callq 0x53a0
movq 0x8(%r14), %rdi
movl $0x20, %esi
callq 0x53a0
movq $0x0, 0x8(%r14)
movb $0x0, (%r14)
movq %r14, %rdi
callq 0xd52a
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x1, %ecx
je 0x142ac
cmpl $0x2, %ecx
jne 0x1437f
movq 0x8(%r14), %rdi
movq 0x10(%r15), %rsi
callq 0x1486a
movq %rax, 0x10(%rbx)
jmp 0x1427d
movq 0x8(%r14), %rdi
movq 0x8(%r15), %rsi
callq 0x14830
movq %rax, 0x8(%rbx)
jmp 0x1427d
movl $0x20, %edi
callq 0x5210
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x2b8bd(%rip), %rsi     # 0x3fb99
leaq 0x2b8d9(%rip), %rdx     # 0x3fbbc
leaq 0x8(%rsp), %rdi
callq 0xaccc
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0xca, %esi
callq 0x14644
xorl %ebp, %ebp
leaq 0x3f5ed(%rip), %rsi     # 0x538f8
leaq -0x2506(%rip), %rdx     # 0x11e0c
movq %rbx, %rdi
callq 0x56b0
jmp 0x1440f
movl $0x20, %edi
callq 0x5210
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x2b881(%rip), %rsi     # 0x3fbbd
leaq 0x2b88f(%rip), %rdx     # 0x3fbd2
leaq 0x8(%rsp), %rdi
callq 0xaccc
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0xcd, %esi
callq 0x14644
xorl %ebp, %ebp
leaq 0x3f58d(%rip), %rsi     # 0x538f8
leaq -0x2566(%rip), %rdx     # 0x11e0c
movq %rbx, %rdi
callq 0x56b0
jmp 0x1440f
movl $0x20, %edi
callq 0x5210
movq %rax, %rbx
movzbl (%r14), %eax
cmpq $0x8, %rax
ja 0x143a3
leaq 0x3f71b(%rip), %rcx     # 0x53ab8
movq (%rcx,%rax,8), %r14
jmp 0x143aa
leaq 0x2a14e(%rip), %r14     # 0x3e4f8
leaq 0x38(%rsp), %r15
movq %r15, -0x10(%r15)
movq %r14, %rdi
callq 0x51f0
leaq (%rax,%r14), %rdx
leaq 0x28(%rsp), %rdi
movq %r14, %rsi
callq 0xaccc
leaq 0x2b800(%rip), %rsi     # 0x3fbd3
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0xc0ee
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0x133, %esi            # imm = 0x133
callq 0xbf2e
xorl %ebp, %ebp
leaq 0x3f438(%rip), %rsi     # 0x53838
leaq -0x25fb(%rip), %rdx     # 0x11e0c
movq %rbx, %rdi
callq 0x56b0
movq %rax, %r14
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x14435
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53a0
jmp 0x14435
movq %rax, %r14
movb $0x1, %bpl
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0x1446e
movq 0x38(%rsp), %rsi
jmp 0x1445e
jmp 0x14468
jmp 0x1444c
jmp 0x14468
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x1446e
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53a0
jmp 0x1446e
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x1447b
movq %rbx, %rdi
callq 0x52d0
movq %r14, %rdi
callq 0x56e0
nop