// File: AgathokakologicalBit[P]wit/src/parsing/parsing.cpp
// Function: akbit::system::parsing::(anonymous namespace)::parse_statement_declaration(akbit::system::parsing::ParserState&)
std::shared_ptr<Node> parse_statement_declaration(ParserState &state)
    {
      state.consume(TokenSubType::t_identifier, "let");
      if (state.is_failed()) return nullptr;

      auto container = std::make_shared<Node>(Node::declaration_t{});
      auto idt = state.consume(TokenType::t_identifier);
      if (state.is_failed()) return container;

      std::get<Node::declaration_t>(container->value).variable = std::make_shared<Node>(Node(Node::value_variable_t{
        .name = idt.value,
      }));
      auto unode = std::make_shared<Node>();
      auto data = parse_expression(unode, state, 2);
      if (data != unode)
      {
        if (data->value.index() == 5 && std::get<Node::binary_operation_t>(data->value).operation == find_operator(":"))
        {
          data = std::get<Node::binary_operation_t>(data->value).operands[1];
        }
        else
        {
          data = unode;
        }
      }
      std::get<Node::declaration_t>(container->value).type = data;

      state.consume(TokenSubType::t_equal);
      if (state.is_failed()) return container;

      std::get<Node::declaration_t>(container->value).value = parse_statement(state);
      return container;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x2b0, %rsp            # imm = 0x2B0
movq %rdi, -0x248(%rbp)
movq %rdi, %rax
movq %rax, -0x240(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x238(%rbp)
leaq -0x69(%rbp), %rdi
movq %rdi, -0x230(%rbp)
callq 0x4570
movq -0x230(%rbp), %rdx
leaq 0x232ec(%rip), %rsi     # 0x368e9
leaq -0x68(%rbp), %rdi
callq 0x9e70
jmp 0x13608
movq -0x238(%rbp), %rsi
leaq -0x48(%rbp), %rdi
movl $0x3, %edx
leaq -0x68(%rbp), %rcx
callq 0x12b50
jmp 0x13623
leaq -0x48(%rbp), %rdi
callq 0xec00
leaq -0x68(%rbp), %rdi
callq 0x4210
leaq -0x69(%rbp), %rdi
callq 0x4370
movq -0x10(%rbp), %rdi
callq 0x15c20
testb $0x1, %al
jne 0x1364d
jmp 0x13693
movq -0x248(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x15c40
jmp 0x13c3d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13685
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x4210
leaq -0x69(%rbp), %rdi
callq 0x4370
jmp 0x13c4d
movb $0x0, -0x7d(%rbp)
leaq -0xb0(%rbp), %rdi
movq %rdi, -0x250(%rbp)
callq 0x18560
leaq -0xa0(%rbp), %rdi
callq 0x18560
leaq -0x90(%rbp), %rdi
callq 0x18560
movq -0x248(%rbp), %rdi
movq -0x250(%rbp), %rsi
callq 0x184f0
jmp 0x136d7
leaq -0xb0(%rbp), %rdi
callq 0xaf50
movq -0x10(%rbp), %rsi
leaq -0xe8(%rbp), %rdi
movl $0x2, %edx
xorl %ecx, %ecx
callq 0x12610
jmp 0x136fc
movq -0x10(%rbp), %rdi
callq 0x15c20
testb $0x1, %al
jne 0x1370b
jmp 0x1374c
movb $0x1, -0x7d(%rbp)
movl $0x1, -0xec(%rbp)
jmp 0x13bff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xaf50
jmp 0x13c4d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13c2f
leaq -0xd8(%rbp), %rsi
leaq -0x188(%rbp), %rdi
callq 0x4160
jmp 0x13761
leaq -0x168(%rbp), %rdi
xorps %xmm0, %xmm0
movups %xmm0, -0x168(%rbp)
callq 0x185f0
leaq -0x158(%rbp), %rdi
leaq -0x188(%rbp), %rsi
callq 0x18610
jmp 0x1378c
leaq -0x100(%rbp), %rdi
leaq -0x158(%rbp), %rsi
callq 0x18580
jmp 0x137a1
movq -0x248(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x18680
movq %rax, -0x258(%rbp)
jmp 0x137c2
movq -0x258(%rbp), %rdi
leaq -0x100(%rbp), %rsi
movq %rsi, -0x260(%rbp)
callq 0x186a0
movq -0x260(%rbp), %rdi
callq 0x9b50
leaq -0x158(%rbp), %rdi
callq 0x17b50
leaq -0x188(%rbp), %rdi
callq 0xc060
leaq -0x198(%rbp), %rdi
callq 0x186d0
jmp 0x1380e
leaq -0x1b8(%rbp), %rdi
movq %rdi, -0x268(%rbp)
leaq -0x198(%rbp), %rsi
callq 0x9b20
movq -0x268(%rbp), %rsi
movq -0x10(%rbp), %rdx
leaq -0x1a8(%rbp), %rdi
movl $0x2, %ecx
callq 0x141c0
jmp 0x13846
leaq -0x1b8(%rbp), %rdi
callq 0x9b50
leaq -0x1a8(%rbp), %rdi
leaq -0x198(%rbp), %rsi
callq 0x18740
testb $0x1, %al
jne 0x1386e
jmp 0x13ace
leaq -0x1a8(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x9e50
movq %rax, %rcx
movb $0x0, -0x1da(%rbp)
movb $0x0, -0x1db(%rbp)
xorl %eax, %eax
cmpq $0x5, %rcx
movb %al, -0x269(%rbp)
jne 0x13947
leaq -0x1a8(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x18780
movq %rax, -0x278(%rbp)
jmp 0x138ca
movq -0x278(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x288(%rbp)
leaq -0x1d9(%rbp), %rdi
movq %rdi, -0x280(%rbp)
callq 0x4570
movq -0x280(%rbp), %rdx
movb $0x1, -0x1da(%rbp)
leaq 0x2295a(%rip), %rsi     # 0x3625d
leaq -0x1d8(%rbp), %rdi
callq 0x9e70
jmp 0x13911
movb $0x1, -0x1db(%rbp)
leaq -0x1d8(%rbp), %rdi
callq 0xfbf0
movq %rax, -0x290(%rbp)
jmp 0x1392d
movq -0x288(%rbp), %rax
movq -0x290(%rbp), %rcx
cmpq %rcx, %rax
sete %al
movb %al, -0x269(%rbp)
movb -0x269(%rbp), %al
movb %al, -0x291(%rbp)
testb $0x1, -0x1db(%rbp)
jne 0x1395e
jmp 0x1396a
leaq -0x1d8(%rbp), %rdi
callq 0x4210
testb $0x1, -0x1da(%rbp)
jne 0x13975
jmp 0x13981
leaq -0x1d9(%rbp), %rdi
callq 0x4370
movb -0x291(%rbp), %al
testb $0x1, %al
jne 0x13990
jmp 0x13ab9
leaq -0x1a8(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x18780
movq %rax, -0x2a0(%rbp)
jmp 0x139b1
movq -0x2a0(%rbp), %rdi
addq $0x8, %rdi
movl $0x1, %esi
callq 0xcaa0
movq %rax, %rsi
leaq -0x1a8(%rbp), %rdi
callq 0x187a0
jmp 0x13acc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13c13
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13a2b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13a1f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x100(%rbp), %rdi
callq 0x9b50
leaq -0x158(%rbp), %rdi
callq 0x17b50
leaq -0x188(%rbp), %rdi
callq 0xc060
jmp 0x13c13
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x1b8(%rbp), %rdi
callq 0x9b50
jmp 0x13bf1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13be5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x13a9d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
testb $0x1, -0x1db(%rbp)
jne 0x13a8f
jmp 0x13a9b
leaq -0x1d8(%rbp), %rdi
callq 0x4210
jmp 0x13a9d
testb $0x1, -0x1da(%rbp)
jne 0x13aa8
jmp 0x13ab4
leaq -0x1d9(%rbp), %rdi
callq 0x4370
jmp 0x13be5
leaq -0x1a8(%rbp), %rdi
leaq -0x198(%rbp), %rsi
callq 0x187a0
jmp 0x13ace
movq -0x248(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x18680
movq %rax, -0x2a8(%rbp)
jmp 0x13aef
movq -0x2a8(%rbp), %rdi
addq $0x10, %rdi
leaq -0x1a8(%rbp), %rsi
callq 0x187a0
movq -0x10(%rbp), %rsi
leaq -0x218(%rbp), %rdi
movl $0x1d, %edx
callq 0x12880
jmp 0x13b1d
leaq -0x218(%rbp), %rdi
callq 0xec00
movq -0x10(%rbp), %rdi
callq 0x15c20
testb $0x1, %al
jne 0x13b38
jmp 0x13b4b
movb $0x1, -0x7d(%rbp)
movl $0x1, -0xec(%rbp)
jmp 0x13bcb
movq -0x10(%rbp), %rsi
leaq -0x228(%rbp), %rdi
callq 0x13390
jmp 0x13b5d
movq -0x248(%rbp), %rdi
callq 0x9b90
movq %rax, %rdi
addq $0x10, %rdi
callq 0x18680
movq %rax, -0x2b0(%rbp)
jmp 0x13b7e
movq -0x2b0(%rbp), %rdi
addq $0x20, %rdi
leaq -0x228(%rbp), %rsi
callq 0x186a0
leaq -0x228(%rbp), %rdi
callq 0x9b50
movb $0x1, -0x7d(%rbp)
movl $0x1, -0xec(%rbp)
jmp 0x13bcb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x228(%rbp), %rdi
callq 0x9b50
jmp 0x13be5
leaq -0x1a8(%rbp), %rdi
callq 0x9b50
leaq -0x198(%rbp), %rdi
callq 0x9b50
jmp 0x13bff
leaq -0x1a8(%rbp), %rdi
callq 0x9b50
leaq -0x198(%rbp), %rdi
callq 0x9b50
jmp 0x13c13
leaq -0xe8(%rbp), %rdi
callq 0xec00
testb $0x1, -0x7d(%rbp)
jne 0x13c2d
jmp 0x13c21
leaq -0xe8(%rbp), %rdi
callq 0xec00
jmp 0x13c2f
movq -0x248(%rbp), %rdi
callq 0x9b50
jmp 0x13c3d
movq -0x248(%rbp), %rdi
callq 0x9b50
jmp 0x13c4d
movq -0x240(%rbp), %rax
addq $0x2b0, %rsp            # imm = 0x2B0
popq %rbp
retq
movq -0x78(%rbp), %rdi
callq 0x4560
nopw %cs:(%rax,%rax)