// File: xelia-it[P]mustache/test/src/../../src/../third-party/json/single_include/nlohmann/json.hpp
// Function: nlohmann::json_abi_v3_11_2::detail::iter_impl<nlohmann::json_abi_v3_11_2::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::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>> nlohmann::json_abi_v3_11_2::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::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::erase<nlohmann::json_abi_v3_11_2::detail::iter_impl<nlohmann::json_abi_v3_11_2::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::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, 0>(nlohmann::json_abi_v3_11_2::detail::iter_impl<nlohmann::json_abi_v3_11_2::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::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>)
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", this));
        }

        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", this));
                }

                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;
            }

            case value_t::null:
            case value_t::discarded:
            default:
                JSON_THROW(type_error::create(307, detail::concat("cannot use erase() with ", type_name()), this));
        }

        return result;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp            # imm = 0x130
movq %rdx, -0xe8(%rbp)
movq %rdi, -0xe0(%rbp)
movq %rdi, %rax
movq %rax, -0xd8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xd0(%rbp)
cmpq (%rdx), %rax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
testb $0x1, %al
jne 0x11f60d
jmp 0x11f6d1
movb $0x1, -0x4d(%rbp)
movl $0x20, %edi
callq 0x52380
movq %rax, -0xf8(%rbp)
leaq -0x39(%rbp), %rdi
movq %rdi, -0xf0(%rbp)
callq 0x52ca0
movq -0xf0(%rbp), %rdx
leaq 0x27faa(%rip), %rsi     # 0x1475ea
leaq -0x38(%rbp), %rdi
callq 0x529e0
jmp 0x11f64b
movq -0xd0(%rbp), %rcx
movq -0xf8(%rbp), %rdi
movl $0xca, %esi
leaq -0x38(%rbp), %rdx
callq 0x123540
jmp 0x11f669
movq -0xf8(%rbp), %rdi
movb $0x0, -0x4d(%rbp)
leaq 0xa13bd(%rip), %rsi     # 0x1c0a38
leaq 0x406e(%rip), %rdx      # 0x1236f0
callq 0x52c20
jmp 0x11fabb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x11f6af
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x52e58
leaq -0x39(%rbp), %rdi
callq 0x527d0
testb $0x1, -0x4d(%rbp)
jne 0x11f6c0
jmp 0x11f6cc
movq -0xf8(%rbp), %rdi
callq 0x52540
jmp 0x11fab2
movq -0xd0(%rbp), %rsi
movq -0xe0(%rbp), %rdi
callq 0x11f330
movq -0xd0(%rbp), %rax
movzbl (%rax), %eax
movq %rax, -0x100(%rbp)
subq $0x9, %rax
ja 0x11f9d8
movq -0x100(%rbp), %rax
leaq 0x24d7f(%rip), %rcx     # 0x14448c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0xe8(%rbp), %rdi
addq $0x8, %rdi
addq $0x10, %rdi
callq 0x1239d0
xorb $-0x1, %al
xorb $-0x1, %al
xorb $-0x1, %al
testb $0x1, %al
jne 0x11f739
jmp 0x11f7fd
movb $0x1, -0x72(%rbp)
movl $0x20, %edi
callq 0x52380
movq %rax, -0x110(%rbp)
leaq -0x71(%rbp), %rdi
movq %rdi, -0x108(%rbp)
callq 0x52ca0
movq -0x108(%rbp), %rdx
leaq 0x27ea2(%rip), %rsi     # 0x14760e
leaq -0x70(%rbp), %rdi
callq 0x529e0
jmp 0x11f777
movq -0xd0(%rbp), %rcx
movq -0x110(%rbp), %rdi
movl $0xcd, %esi
leaq -0x70(%rbp), %rdx
callq 0x123540
jmp 0x11f795
movq -0x110(%rbp), %rdi
movb $0x0, -0x72(%rbp)
leaq 0xa1291(%rip), %rsi     # 0x1c0a38
leaq 0x3f42(%rip), %rdx      # 0x1236f0
callq 0x52c20
jmp 0x11fabb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x11f7db
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x52e58
leaq -0x71(%rbp), %rdi
callq 0x527d0
testb $0x1, -0x72(%rbp)
jne 0x11f7ec
jmp 0x11f7f8
movq -0x110(%rbp), %rdi
callq 0x52540
jmp 0x11fab2
movq -0xd0(%rbp), %rdi
callq 0x1239f0
testb $0x1, %al
jne 0x11f80f
jmp 0x11f88b
leaq -0x73(%rbp), %rdi
movq %rdi, -0x118(%rbp)
callq 0x98250
movq -0xd0(%rbp), %rax
movq -0x118(%rbp), %rdi
movq 0x8(%rax), %rsi
callq 0x98b00
movq -0xd0(%rbp), %rax
movq -0x118(%rbp), %rdi
movq 0x8(%rax), %rsi
movl $0x1, %edx
callq 0xac5d0
jmp 0x11f854
movq -0xd0(%rbp), %rax
movq $0x0, 0x8(%rax)
leaq -0x73(%rbp), %rdi
callq 0x98270
jmp 0x11f918
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x73(%rbp), %rdi
callq 0x98270
jmp 0x11fab2
movq -0xd0(%rbp), %rdi
callq 0x123a10
testb $0x1, %al
jne 0x11f89d
jmp 0x11f916
leaq -0x74(%rbp), %rdi
movq %rdi, -0x120(%rbp)
callq 0x113010
movq -0xd0(%rbp), %rax
movq -0x120(%rbp), %rdi
movq 0x8(%rax), %rsi
callq 0x123a30
movq -0xd0(%rbp), %rax
movq -0x120(%rbp), %rdi
movq 0x8(%rax), %rsi
movl $0x1, %edx
callq 0x113780
jmp 0x11f8e2
movq -0xd0(%rbp), %rax
movq $0x0, 0x8(%rax)
leaq -0x74(%rbp), %rdi
callq 0x1131b0
jmp 0x11f916
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x74(%rbp), %rdi
callq 0x1131b0
jmp 0x11fab2
jmp 0x11f918
movq -0xd0(%rbp), %rdi
movb $0x0, (%rdi)
movl $0x1, %esi
callq 0x111360
jmp 0x11faa2
movq -0xe8(%rbp), %rax
movq -0xd0(%rbp), %rcx
movq 0x8(%rcx), %rdi
movq 0x8(%rax), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rsi
callq 0x123a60
movq %rax, %rcx
movq -0xe0(%rbp), %rax
movq %rcx, -0x80(%rbp)
movq -0x80(%rbp), %rcx
movq %rcx, 0x8(%rax)
jmp 0x11faa2
movq -0xe8(%rbp), %rsi
movq -0xd0(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x128(%rbp)
addq $0x8, %rsi
addq $0x8, %rsi
leaq -0x98(%rbp), %rdi
callq 0x123b10
movq -0x128(%rbp), %rdi
movq -0x98(%rbp), %rsi
callq 0x123aa0
movq %rax, %rcx
movq -0xe0(%rbp), %rax
movq %rcx, -0x90(%rbp)
movq -0x90(%rbp), %rcx
movq %rcx, 0x10(%rax)
jmp 0x11faa2
jmp 0x11f9d8
movb $0x1, -0xc1(%rbp)
movl $0x20, %edi
callq 0x52380
movq -0xd0(%rbp), %rdi
movq %rax, -0x130(%rbp)
callq 0x123da0
movq %rax, -0xc0(%rbp)
leaq 0x27c1a(%rip), %rsi     # 0x147624
leaq -0xb8(%rbp), %rdi
leaq -0xc0(%rbp), %rdx
callq 0x123d00
jmp 0x11fa1f
movq -0xd0(%rbp), %rcx
movq -0x130(%rbp), %rdi
movl $0x133, %esi            # imm = 0x133
leaq -0xb8(%rbp), %rdx
callq 0x123b50
jmp 0x11fa40
movq -0x130(%rbp), %rdi
movb $0x0, -0xc1(%rbp)
leaq 0xa1023(%rip), %rsi     # 0x1c0a78
leaq 0x43e4(%rip), %rdx      # 0x123e40
callq 0x52c20
jmp 0x11fabb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x11fa89
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0xb8(%rbp), %rdi
callq 0x52e58
testb $0x1, -0xc1(%rbp)
jne 0x11fa94
jmp 0x11faa0
movq -0x130(%rbp), %rdi
callq 0x52540
jmp 0x11fab2
movq -0xd8(%rbp), %rax
addq $0x130, %rsp            # imm = 0x130
popq %rbp
retq
movq -0x48(%rbp), %rdi
callq 0x52c90
nopl (%rax,%rax)