// File: /workspace/github_c_makefile_star2_O0/voithos[P]awl/src/parser.c
// Function: awlval_read
static awlval* awlval_read(const mpc_ast_t* t) {
    if (strstr(t->tag, "integer")) {
        return awlval_read_int(t);
    }
    if (strstr(t->tag, "fpoint")) {
        return awlval_read_float(t);
    }
    if (strstr(t->tag, "bool")) {
        return awlval_read_bool(t);
    }
    if (strstr(t->tag, "string")) {
        return awlval_read_string(t);
    }
    if (strstr(t->tag, "qsymbol")) {
        return awlval_read_qsym(t);
    }
    if (strstr(t->tag, "symbol")) {
        return awlval_read_sym(t);
    }
    if (strstr(t->tag, "dict")) {
        return awlval_read_dict(t);
    }

    awlval* x = NULL;
    /* If root '>' */
    if (streq(t->tag, ">")) {
        x = awlval_sexpr();
    }
    else if (strstr(t->tag, "sexpr")) {
        x = awlval_sexpr();
    }
    else if (strstr(t->tag, "qexpr")) {
        x = awlval_qexpr();
    }
    else if (strstr(t->tag, "eexpr")) {
        x = awlval_eexpr();
    }
    else if (strstr(t->tag, "cexpr")) {
        x = awlval_cexpr();
    }

    for (int i = 0; i < t->children_num; i++) {
        if (streq(t->children[i]->contents, "(")) { continue; }
        if (streq(t->children[i]->contents, ")")) { continue; }
        if (streq(t->children[i]->contents, "{")) { continue; }
        if (streq(t->children[i]->contents, "}")) { continue; }
        if (streq(t->children[i]->contents, ":")) { continue; }
        if (streq(t->children[i]->contents, "\\")) { continue; }
        if (streq(t->children[i]->contents, "@")) { continue; }
        if (streq(t->children[i]->tag, "regex")) { continue; }
        if (strstr(t->children[i]->tag, "comment")) { continue; }
        x = awlval_add(x, awlval_read(t->children[i]));
    }

    return x;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x60a7(%rip), %rsi      # 0x1b001
callq 0x2370
cmpq $0x0, %rax
je 0x14f77
movq -0x10(%rbp), %rdi
callq 0x153a0
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6338(%rip), %rsi      # 0x1b2bd
callq 0x2370
cmpq $0x0, %rax
je 0x14fa2
movq -0x10(%rbp), %rdi
callq 0x15410
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6314(%rip), %rsi      # 0x1b2c4
callq 0x2370
cmpq $0x0, %rax
je 0x14fcd
movq -0x10(%rbp), %rdi
callq 0x15480
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6063(%rip), %rsi      # 0x1b03e
callq 0x2370
cmpq $0x0, %rax
je 0x14ff8
movq -0x10(%rbp), %rdi
callq 0x154d0
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x62cb(%rip), %rsi      # 0x1b2d1
callq 0x2370
cmpq $0x0, %rax
je 0x15023
movq -0x10(%rbp), %rdi
callq 0x15570
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x56e5(%rip), %rsi      # 0x1a716
callq 0x2370
cmpq $0x0, %rax
je 0x1504e
movq -0x10(%rbp), %rdi
callq 0x15670
movq %rax, -0x8(%rbp)
jmp 0x15310
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6289(%rip), %rsi      # 0x1b2e5
callq 0x2370
cmpq $0x0, %rax
je 0x15079
movq -0x10(%rbp), %rdi
callq 0x15690
movq %rax, -0x8(%rbp)
jmp 0x15310
movq $0x0, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6187(%rip), %rsi      # 0x1b216
callq 0x18d50
testb $0x1, %al
jne 0x1509a
jmp 0x150a8
callq 0x16bb0
movq %rax, -0x18(%rbp)
jmp 0x1513e
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6223(%rip), %rsi      # 0x1b2d9
callq 0x2370
cmpq $0x0, %rax
je 0x150cc
callq 0x16bb0
movq %rax, -0x18(%rbp)
jmp 0x1513c
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x6205(%rip), %rsi      # 0x1b2df
callq 0x2370
cmpq $0x0, %rax
je 0x150f0
callq 0x16c00
movq %rax, -0x18(%rbp)
jmp 0x1513a
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x61ec(%rip), %rsi      # 0x1b2ea
callq 0x2370
cmpq $0x0, %rax
je 0x15114
callq 0x16c50
movq %rax, -0x18(%rbp)
jmp 0x15138
movq -0x10(%rbp), %rax
movq (%rax), %rdi
leaq 0x61ce(%rip), %rsi      # 0x1b2f0
callq 0x2370
cmpq $0x0, %rax
je 0x15136
callq 0x16ca0
movq %rax, -0x18(%rbp)
jmp 0x15138
jmp 0x1513a
jmp 0x1513c
jmp 0x1513e
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x1c(%rcx), %eax
jge 0x15308
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x5edb(%rip), %rsi      # 0x1b04b
callq 0x18d50
testb $0x1, %al
jne 0x1517b
jmp 0x15180
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x5eb2(%rip), %rsi      # 0x1b04d
callq 0x18d50
testb $0x1, %al
jne 0x151a6
jmp 0x151ab
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x5e89(%rip), %rsi      # 0x1b04f
callq 0x18d50
testb $0x1, %al
jne 0x151d1
jmp 0x151d6
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x605b(%rip), %rsi      # 0x1b24c
callq 0x18d50
testb $0x1, %al
jne 0x151fc
jmp 0x15201
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x609d(%rip), %rsi      # 0x1b2b9
callq 0x18d50
testb $0x1, %al
jne 0x15227
jmp 0x1522c
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x5fab(%rip), %rsi      # 0x1b1f2
callq 0x18d50
testb $0x1, %al
jne 0x15252
jmp 0x15257
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq 0x8(%rax), %rdi
leaq 0x65d0(%rip), %rsi      # 0x1b842
callq 0x18d50
testb $0x1, %al
jne 0x1527d
jmp 0x1527f
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq (%rax), %rdi
leaq 0x5dac(%rip), %rsi      # 0x1b045
callq 0x18d50
testb $0x1, %al
jne 0x152a4
jmp 0x152a6
jmp 0x152fa
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq (%rax), %rdi
leaq 0x6009(%rip), %rsi      # 0x1b2c9
callq 0x2370
cmpq $0x0, %rax
je 0x152cd
jmp 0x152fa
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x14f40
movq -0x28(%rbp), %rdi
movq %rax, %rsi
callq 0x16e70
movq %rax, -0x18(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x15145
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)