// File: /workspace/github_cpp_makefile_star2_O1/pfnet-research[P]pml/src/parser.cpp
// Function: parser::refty_detail(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long&)
refty_result_t refty_detail(std::string const& input, size_t& pos) {
    EXPECT(lbrace_token, LBrace);
    EXPECT(ident_token, Ident);
    EXPECT(colon_token, Colon);
    auto sty_result = simple_type(input, pos);
    if (sty_result.is_error())
        return sty_result.convert<ast::refinement_type_t>();
    EXPECT(bar_token, Bar);
    auto constraint_result = formula(input, pos);
    if (constraint_result.is_error())
        return constraint_result.convert<ast::refinement_type_t>();
    EXPECT(rbrace_token, RBrace);
    return refty_result_t::ok(ast::refinement_type_t {
            ident_token.lexime, sty_result.ok(), constraint_result.ok()
            });
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2b8, %rsp            # imm = 0x2B8
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdx), %rdx
leaq 0x280(%rsp), %r12
movq %r12, %rdi
movl $0x1d, %ecx
callq 0x1c868
cmpb $0x0, 0x30(%r12)
je 0x1fc97
leaq 0x280(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x140(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x150(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x148(%rsp), %rdx
addq 0x138(%rsp), %rdx
movq %rdx, (%r14)
leaq 0x248(%rsp), %rdi
movq %r15, %rsi
movl $0xa, %ecx
callq 0x1c868
cmpb $0x0, 0x278(%rsp)
je 0x1fcb4
leaq 0x248(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x40(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x50(%rsp), %r13
movq %r13, -0x10(%r13)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x48(%rsp), %rdx
addq 0x38(%rsp), %rdx
movq %rdx, (%r14)
leaq 0x210(%rsp), %rdi
movq %r15, %rsi
movl $0x1c, %ecx
callq 0x1c868
cmpb $0x0, 0x240(%rsp)
je 0x1fcd1
leaq 0x210(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x110(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x120(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x118(%rsp), %rax
addq 0x108(%rsp), %rax
movq %rax, (%r14)
leaq 0x98(%rsp), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x1f1a8
cmpb $0x0, 0xc8(%rsp)
je 0x1fcee
movq (%r14), %rdx
leaq 0x1d8(%rsp), %rdi
movq %r15, %rsi
movl $0x1b, %ecx
callq 0x1c868
cmpb $0x0, 0x208(%rsp)
je 0x1fd0b
leaq 0x1d8(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0x10(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0x20(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0x18(%rsp), %rax
addq 0x8(%rsp), %rax
movq %rax, (%r14)
leaq 0x1a0(%rsp), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x1ef2d
cmpb $0x0, 0x1d0(%rsp)
je 0x1fd28
movq (%r14), %rdx
leaq 0x168(%rsp), %rdi
movq %r15, %rsi
movl $0x1e, %ecx
callq 0x1c868
cmpb $0x0, 0x198(%rsp)
je 0x1fd45
leaq 0x168(%rsp), %rdi
callq 0x2494c
movups (%rax), %xmm0
leaq 0xe0(%rsp), %rdi
movaps %xmm0, -0x10(%rdi)
leaq 0xf0(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
addq %rsi, %rdx
callq 0xad30
movq 0xe8(%rsp), %rax
addq 0xd8(%rsp), %rax
movq %rax, (%r14)
leaq 0x70(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x40(%rsp), %rsi
movq 0x48(%rsp), %rdx
addq %rsi, %rdx
leaq 0x60(%rsp), %rdi
callq 0xad30
leaq 0x98(%rsp), %rdi
callq 0x24b88
movl (%rax), %eax
movl %eax, 0x80(%rsp)
leaq 0x1a0(%rsp), %rdi
callq 0x249a6
movq (%rax), %rcx
movq %rcx, 0x88(%rsp)
movq 0x8(%rax), %rax
movq %rax, 0x90(%rsp)
testq %rax, %rax
je 0x1fd66
movq 0x4332a(%rip), %rcx     # 0x62fb0
cmpb $0x0, (%rcx)
je 0x1fd62
incl 0x8(%rax)
jmp 0x1fd66
leaq 0x280(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fec7
leaq 0x248(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fe9d
leaq 0x210(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fe79
leaq 0x98(%rsp), %rdi
callq 0x283e6
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fe31
leaq 0x1d8(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fe24
leaq 0x1a0(%rsp), %rdi
callq 0x28294
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fdfb
leaq 0x168(%rsp), %rdi
callq 0x248f2
movq %rbx, %rdi
movq %rax, %rsi
callq 0x24c0e
jmp 0x1fdee
lock
incl 0x8(%rax)
movb $0x1, 0x38(%rbx)
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq 0x60(%rsp), %rcx
cmpq %r14, %rcx
je 0x1fd89
movq %rcx, (%rbx)
movq 0x70(%rsp), %rax
movq %rax, 0x10(%rbx)
jmp 0x1fd90
movups (%r14), %xmm0
movups %xmm0, (%rax)
leaq 0x60(%rsp), %rdi
movq 0x8(%rdi), %rax
movq %rax, 0x8(%rbx)
movq %r14, (%rdi)
xorl %eax, %eax
movq %rax, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
movl 0x20(%rdi), %ecx
movl %ecx, 0x20(%rbx)
movq 0x28(%rdi), %rcx
movq %rcx, 0x28(%rbx)
movq %rax, 0x30(%rbx)
movq 0x30(%rdi), %rcx
movq %rax, 0x30(%rdi)
movq %rcx, 0x30(%rbx)
movq %rax, 0x28(%rdi)
callq 0x24c5c
movq 0xe0(%rsp), %rdi
cmpq %r15, %rdi
je 0x1fdee
movq 0xf0(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x168(%rsp), %rdi
callq 0x28218
leaq 0x1a0(%rsp), %rdi
callq 0x28264
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x1fe24
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x1d8(%rsp), %rdi
callq 0x28218
cmpb $0x0, 0xc8(%rsp)
jne 0x1fe5c
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1fe5c
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x92e0
movq 0x110(%rsp), %rdi
cmpq %rbp, %rdi
je 0x1fe79
movq 0x120(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x210(%rsp), %rdi
callq 0x28218
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x1fe9d
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x248(%rsp), %rdi
callq 0x28218
movq 0x140(%rsp), %rdi
cmpq %r12, %rdi
je 0x1fec7
movq 0x150(%rsp), %rsi
incq %rsi
callq 0x92e0
leaq 0x280(%rsp), %rdi
callq 0x28218
movq %rbx, %rax
addq $0x2b8, %rsp            # imm = 0x2B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x1ff08
movq %rax, %rbx
movq 0x60(%rsp), %rdi
cmpq %r14, %rdi
je 0x1ff08
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x92e0
movq 0xe0(%rsp), %rdi
cmpq %r15, %rdi
je 0x1ff2c
movq 0xf0(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x1ff2c
jmp 0x1ff29
movq %rax, %rbx
leaq 0x168(%rsp), %rdi
callq 0x28218
jmp 0x1ff40
jmp 0x1ff3d
movq %rax, %rbx
leaq 0x1a0(%rsp), %rdi
callq 0x28264
jmp 0x1ff52
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x1ff75
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x1ff75
jmp 0x1ff72
movq %rax, %rbx
leaq 0x1d8(%rsp), %rdi
callq 0x28218
jmp 0x1ff89
jmp 0x1ff86
movq %rax, %rbx
cmpb $0x0, 0xc8(%rsp)
jne 0x1ffb9
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1ffb9
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x1ffb9
movq %rax, %rbx
movq 0x110(%rsp), %rdi
cmpq %rbp, %rdi
je 0x1ffdd
movq 0x120(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x1ffdd
jmp 0x1ffda
movq %rax, %rbx
leaq 0x210(%rsp), %rdi
callq 0x28218
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x2000d
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x2000d
movq %rax, %rbx
jmp 0x1ffea
jmp 0x2000a
movq %rax, %rbx
leaq 0x248(%rsp), %rdi
callq 0x28218
movq 0x140(%rsp), %rdi
cmpq %r12, %rdi
je 0x20043
movq 0x150(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x20043
movq %rax, %rbx
jmp 0x2001a
jmp 0x20040
movq %rax, %rbx
leaq 0x280(%rsp), %rdi
callq 0x28218
movq %rbx, %rdi
callq 0x94e0