// File: /workspace/github_cpp_makefile_star2_O1/pfnet-research[P]pml/src/parser.cpp
// Function: parser::dependent_type(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long&)
depty_result_t dependent_type(std::string const& input, size_t& pos) {
    auto token = next_token(input, pos);
    std::vector<ast::refinement_type_t> args;
    if (token.kind == token_t::kind_t::LParen) {
        EXPECT(lparen_token, LParen);
        auto refty_result = refinement_type(input, pos);
        if (refty_result.is_error())
            return refty_result.convert<ast::dependent_type_t>();
        args.push_back(refty_result.ok());
        while (true) {
            if (next_token(input, pos).kind != token_t::kind_t::Comma)
                break;
            EXPECT(comma_token, Comma);
            auto refty_result = refinement_type(input, pos);
            if (refty_result.is_error())
                return refty_result.convert<ast::dependent_type_t>();
            args.push_back(refty_result.ok());
        }
        EXPECT(rparen_token, RParen);
    } else {
        auto refty_result = refinement_type(input, pos);
        if (refty_result.is_error())
            return refty_result.convert<ast::dependent_type_t>();
        args.push_back(refty_result.ok());
    }
    EXPECT(arrow_token, Arrow);
    auto retty_result = refinement_type(input, pos);
    if (retty_result.is_error())
        return retty_result.convert<ast::dependent_type_t>();
    return depty_result_t::ok(ast::dependent_type_t {
            args, retty_result.ok()
            });
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1b8, %rsp            # imm = 0x1B8
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdx), %rdx
leaq 0x188(%rsp), %r12
movq %r12, %rdi
callq 0x1bcc7
xorps %xmm0, %xmm0
movaps %xmm0, 0x90(%rsp)
movq $0x0, 0xa0(%rsp)
cmpl $0x1f, (%r12)
movq %rbx, %r12
jne 0x2078f
movq (%r14), %rdx
leaq 0x150(%rsp), %rdi
movq %r15, %rsi
movl $0x1f, %ecx
callq 0x1c868
cmpb $0x0, 0x180(%rsp)
je 0x207bf
leaq 0x150(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x100(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x110(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x108(%rsp), %rax
addq 0xf8(%rsp), %rax
movq %rax, (%r14)
movq %rsp, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x204de
cmpb $0x0, 0x38(%rsp)
je 0x2091e
movq %rsp, %rdi
callq 0x24e06
leaq 0x90(%rsp), %rdi
movq %rax, %rsi
callq 0x24ddc
leaq 0xb0(%rsp), %r13
leaq 0x50(%rsp), %rbp
movq (%r14), %rdx
movq %r13, %rdi
movq %r15, %rsi
callq 0x1bcc7
movl 0xb0(%rsp), %ebx
movq 0xc0(%rsp), %rdi
leaq 0xd0(%rsp), %rax
cmpq %rax, %rdi
je 0x2068f
movq 0xd0(%rsp), %rsi
incq %rsi
callq 0x92e0
cmpl $0x12, %ebx
jne 0x20953
movq (%r14), %rdx
movq %rbp, %rdi
movq %r15, %rsi
movl $0x12, %ecx
callq 0x1c868
cmpb $0x0, 0x80(%rsp)
je 0x209d7
movq %rbp, %rdi
callq 0x2494c
movups (%rax), %xmm0
movaps %xmm0, 0x120(%rsp)
leaq 0x140(%rsp), %rcx
movq %rcx, 0x130(%rsp)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
leaq 0x130(%rsp), %rdi
callq 0xad30
movq 0x138(%rsp), %rax
addq 0x128(%rsp), %rax
movq %rax, (%r14)
movq %r13, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x204de
movb 0xe8(%rsp), %bl
testb %bl, %bl
je 0x2073a
movq %r13, %rdi
callq 0x24e06
leaq 0x90(%rsp), %rdi
movq %rax, %rsi
callq 0x24ddc
jmp 0x2074d
movq %r13, %rdi
callq 0x2852e
movq %r12, %rdi
movq %rax, %rsi
callq 0x24d8e
movq %r13, %rdi
callq 0x28440
movq 0x130(%rsp), %rdi
leaq 0x140(%rsp), %rax
cmpq %rax, %rdi
je 0x2077a
movq 0x140(%rsp), %rsi
incq %rsi
callq 0x92e0
movq %rbp, %rdi
callq 0x28218
testb %bl, %bl
jne 0x20655
jmp 0x209f9
movq %rsp, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x204de
movb 0x38(%rsp), %bl
testb %bl, %bl
je 0x207dc
movq %rsp, %rdi
callq 0x24e06
leaq 0x90(%rsp), %rdi
movq %rax, %rsi
callq 0x24ddc
jmp 0x207ef
leaq 0x150(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24d8e
jmp 0x20b88
movq %rsp, %rdi
callq 0x2852e
movq %r12, %rdi
movq %rax, %rsi
callq 0x24d8e
movq %rsp, %rdi
callq 0x28440
testb %bl, %bl
movq %r12, %rbx
je 0x20b95
movq (%r14), %rdx
leaq 0x150(%rsp), %rdi
movq %r15, %rsi
movl $0xb, %ecx
callq 0x1c868
cmpb $0x0, 0x180(%rsp)
je 0x20901
leaq 0x150(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x60(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x70(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x68(%rsp), %rax
addq 0x58(%rsp), %rax
movq %rax, (%r14)
leaq 0xb0(%rsp), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x204de
cmpb $0x0, 0xe8(%rsp)
je 0x20936
movq %rsp, %rdi
leaq 0x90(%rsp), %rsi
callq 0xcede
leaq 0xb0(%rsp), %rdi
callq 0x24e06
movq %rax, %r14
leaq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movl 0x20(%r14), %eax
movl %eax, 0x38(%rsp)
movq 0x28(%r14), %rax
movq %rax, 0x40(%rsp)
movq 0x30(%r14), %rax
movq %rax, 0x48(%rsp)
testq %rax, %rax
je 0x20aaf
movq 0x426c0(%rip), %rcx     # 0x62fb0
cmpb $0x0, (%rcx)
je 0x20aab
incl 0x8(%rax)
jmp 0x20aaf
leaq 0x150(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24d8e
jmp 0x20b88
movq %rsp, %rdi
callq 0x2852e
movq %r12, %rdi
movq %rax, %rsi
callq 0x24d8e
jmp 0x209f9
leaq 0xb0(%rsp), %rdi
callq 0x2852e
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24d8e
jmp 0x20b64
movq (%r14), %rdx
leaq 0xb0(%rsp), %rdi
movq %r15, %rsi
movl $0x20, %ecx
callq 0x1c868
movb 0xe0(%rsp), %bpl
testb %bpl, %bpl
je 0x20a3b
leaq 0xb0(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x60(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x70(%rsp), %rbx
movq %rbx, -0x10(%rbx)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x68(%rsp), %rax
addq 0x58(%rsp), %rax
movq %rax, (%r14)
movq 0x60(%rsp), %rdi
cmpq %rbx, %rdi
je 0x209d2
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x92e0
movq %r12, %rbx
jmp 0x20a56
movq %r12, %rbx
leaq 0x50(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24d8e
leaq 0x50(%rsp), %rdi
callq 0x28218
movq %rsp, %rdi
callq 0x28440
movq 0x100(%rsp), %rdi
leaq 0x110(%rsp), %rax
cmpq %rax, %rdi
je 0x20a26
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x150(%rsp), %rdi
callq 0x28218
movq %r12, %rbx
jmp 0x20b95
movq %r12, %rbx
leaq 0xb0(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24d8e
leaq 0xb0(%rsp), %rdi
callq 0x28218
movq %rsp, %rdi
callq 0x28440
movq 0x100(%rsp), %rdi
leaq 0x110(%rsp), %rax
cmpq %rax, %rdi
je 0x20a90
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x150(%rsp), %rdi
callq 0x28218
testb %bpl, %bpl
jne 0x20802
jmp 0x20b95
lock
incl 0x8(%rax)
movb $0x1, 0x50(%rbx)
movq (%rsp), %rax
movq %rax, (%rbx)
movq 0x8(%rsp), %rax
movq %rax, 0x8(%rbx)
movq 0x10(%rsp), %rax
movq %rax, 0x10(%rbx)
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
leaq 0x28(%rbx), %rax
movq %rax, 0x18(%rbx)
movq 0x18(%rsp), %rcx
cmpq %r15, %rcx
je 0x20afd
movq %rcx, 0x18(%rbx)
movq 0x28(%rsp), %rax
movq %rax, 0x28(%rbx)
jmp 0x20b04
movups (%r15), %xmm0
movups %xmm0, (%rax)
movq 0x20(%rsp), %rax
movq %rax, 0x20(%rbx)
movq %r15, 0x18(%rsp)
xorl %eax, %eax
movq %rax, 0x20(%rsp)
movb $0x0, 0x28(%rsp)
movl 0x38(%rsp), %ecx
movl %ecx, 0x38(%rbx)
movq 0x40(%rsp), %rcx
movq %rcx, 0x40(%rbx)
movq %rax, 0x48(%rbx)
movq 0x48(%rsp), %rcx
movq %rax, 0x48(%rsp)
movq %rcx, 0x48(%rbx)
movq %rax, 0x40(%rsp)
movq 0x18(%rsp), %rdi
cmpq %r15, %rdi
je 0x20b5c
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x92e0
movq %rsp, %rdi
callq 0xcf76
leaq 0xb0(%rsp), %rdi
callq 0x28440
movq 0x60(%rsp), %rdi
cmpq %r12, %rdi
je 0x20b88
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x150(%rsp), %rdi
callq 0x28218
leaq 0x90(%rsp), %rdi
callq 0xcf76
leaq 0x1a8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x20bc3
movq 0x1a8(%rsp), %rsi
incq %rsi
callq 0x92e0
movq %rbx, %rax
addq $0x1b8, %rsp            # imm = 0x1B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x20bda
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
jmp 0x20ca9
jmp 0x20c65
jmp 0x20bfd
jmp 0x20c6a
movq %rax, %rbx
movq %rsp, %rdi
callq 0xcf76
jmp 0x20c00
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0x28440
jmp 0x20c12
movq %rax, %rbx
movq 0x60(%rsp), %rdi
cmpq %r12, %rdi
je 0x20cdb
movq 0x70(%rsp), %rsi
jmp 0x20cd3
movq %rax, %rbx
jmp 0x20cb6
jmp 0x20c3c
jmp 0x20c3c
jmp 0x20c46
jmp 0x20c65
jmp 0x20c3c
movq %rax, %rbx
jmp 0x20cdb
jmp 0x20c46
movq %rax, %rbx
jmp 0x20ce8
movq %rax, %rbx
movq %rsp, %rdi
callq 0x28440
jmp 0x20ce8
movq %rax, %rbx
jmp 0x20c7f
jmp 0x20c65
movq %rax, %rbx
jmp 0x20cae
movq %rax, %rbx
jmp 0x20ca4
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0x28440
movq 0x130(%rsp), %rdi
leaq 0x140(%rsp), %rax
cmpq %rax, %rdi
je 0x20ca4
movq 0x140(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x50(%rsp), %rdi
callq 0x28218
movq %rsp, %rdi
callq 0x28440
movq 0x100(%rsp), %rdi
leaq 0x110(%rsp), %rax
cmpq %rax, %rdi
je 0x20cdb
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x150(%rsp), %rdi
callq 0x28218
leaq 0x90(%rsp), %rdi
callq 0xcf76
leaq 0x1a8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x20d16
movq 0x1a8(%rsp), %rsi
incq %rsi
callq 0x92e0
movq %rbx, %rdi
callq 0x94e0