// File: /workspace/github_c_makefile_star2_O0/mahrr[P]raven/src/lexer.c
// Function: identifier_type
static TokenType identifier_type(Lexer *lexer) {
#define Is_Keyword(start, rest, type)                       \
    is_keyword(lexer, start, sizeof(rest) - 1, rest, type)

    switch (lexer->start[0]) {
    case 'b': return Is_Keyword(1, "reak",  TOKEN_BREAK);
    case 'd': return Is_Keyword(1, "o",     TOKEN_DO);
    case 'l': return Is_Keyword(1, "et",    TOKEN_LET);
    case 'm': return Is_Keyword(1, "atch",  TOKEN_MATCH);
    case 'o': return Is_Keyword(1, "r",     TOKEN_OR);
    case 'r': return Is_Keyword(1, "eturn", TOKEN_RETURN);
    case 'w': return Is_Keyword(1, "hile",  TOKEN_WHILE);

    case 'a':
        if (lexer->current - lexer->start < 3) break;

        switch (lexer->start[1]) {
        case 'n': return Is_Keyword(2, "d",    TOKEN_AND);
        }
        break;

    case 'c':
        if (lexer->current - lexer->start < 4) break;
        if (lexer->start[1] != 'o') break;
        if (lexer->start[2] != 'n') break;

        switch (lexer->start[3]) {
        case 'd': return Is_Keyword(4, "",     TOKEN_COND);
        case 't': return Is_Keyword(4, "inue", TOKEN_CONTINUE);
        }
        break;

    case 'e':
        if (lexer->current - lexer->start < 3) break;

        switch (lexer->start[1]) {
        case 'n': return Is_Keyword(2, "d",  TOKEN_END);
        case 'l': return Is_Keyword(2, "se", TOKEN_ELSE);
        }
        break;

    case 'f':
        if (lexer->current - lexer->start < 2) break;

        switch (lexer->start[1]) {
        case 'a': return Is_Keyword(2, "lse", TOKEN_FALSE);
        case 'n': return Is_Keyword(2, "",    TOKEN_FN);
        case 'o': return Is_Keyword(2, "r",   TOKEN_FOR);
        }
        break;


    case 'n':
        if (lexer->current - lexer->start != 3) break;

        switch (lexer->start[1]) {
        case 'i': return Is_Keyword(2, "l", TOKEN_NIL);
        case 'o': return Is_Keyword(2, "t", TOKEN_NOT);
        }
        break;

    case 'i':
        if (lexer->current - lexer->start != 2) break;

        switch (lexer->start[1]) {
        case 'f': return TOKEN_IF;
        case 'n': return TOKEN_IN;
        }
        break;


    case 't':
        if (lexer->current - lexer->start < 4) break;

        switch (lexer->start[1]) {
        case 'r': return Is_Keyword(2, "ue", TOKEN_TRUE);
        case 'y': return Is_Keyword(2, "pe", TOKEN_TYPE);
        }
        break;
    }

    return TOKEN_IDENTIFIER;

#undef Is_Keyword
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl (%rax), %eax
addl $-0x61, %eax
movl %eax, %ecx
movq %rcx, -0x18(%rbp)
subl $0x16, %eax
ja 0xcae2
movq -0x18(%rbp), %rax
leaq 0x2a2c(%rip), %rcx      # 0xf020
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x4, %edx
leaq 0x2a90(%rip), %rcx      # 0xf0a2
xorl %r8d, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %edx
leaq 0x2a75(%rip), %rcx      # 0xf0a7
movl $0x22, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x2, %edx
leaq 0x2684(%rip), %rcx      # 0xece0
movl $0x9, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x4, %edx
leaq 0x2a25(%rip), %rcx      # 0xf0a9
movl $0xa, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %edx
leaq 0x1b08(%rip), %rcx      # 0xe1af
movl $0x18, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x5, %edx
leaq 0x29dd(%rip), %rcx      # 0xf0ae
movl $0xc, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x4, %edx
leaq 0x29bb(%rip), %rcx      # 0xf0b4
movl $0xd, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x3, %rax
jge 0xc72a
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movb 0x1(%rax), %al
subb $0x6e, %al
jne 0xc763
jmp 0xc73b
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x1, %edx
leaq 0x1e60(%rip), %rcx      # 0xe5b0
movl $0x17, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x4, %rax
jge 0xc786
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
cmpl $0x6f, %eax
je 0xc79c
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x2(%rax), %eax
cmpl $0x6e, %eax
je 0xc7b2
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x3(%rax), %eax
movl %eax, -0x1c(%rbp)
subl $0x64, %eax
je 0xc7d2
jmp 0xc7c8
movl -0x1c(%rbp), %eax
subl $0x74, %eax
je 0xc7f7
jmp 0xc81c
movq -0x10(%rbp), %rdi
movl $0x4, %esi
xorl %edx, %edx
leaq 0x1873(%rip), %rcx      # 0xe057
movl $0x1, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x4, %edx
leaq 0x28b2(%rip), %rcx      # 0xf0b9
movl $0x2, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x3, %rax
jge 0xc83f
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
movl %eax, -0x20(%rbp)
subl $0x6c, %eax
je 0xc887
jmp 0xc855
movl -0x20(%rbp), %eax
subl $0x6e, %eax
jne 0xc8ac
jmp 0xc85f
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x1, %edx
leaq 0x1d3c(%rip), %rcx      # 0xe5b0
movl $0x23, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x2, %edx
leaq 0x1de3(%rip), %rcx      # 0xe67a
movl $0x3, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x2, %rax
jge 0xc8cf
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
movl %eax, -0x24(%rbp)
subl $0x61, %eax
je 0xc8f9
jmp 0xc8e5
movl -0x24(%rbp), %eax
subl $0x6e, %eax
je 0xc921
jmp 0xc8ef
movl -0x24(%rbp), %eax
subl $0x6f, %eax
je 0xc946
jmp 0xc96e
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x3, %edx
leaq 0x1d6b(%rip), %rcx      # 0xe679
movl $0x4, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x2, %esi
xorl %edx, %edx
leaq 0x1724(%rip), %rcx      # 0xe057
movl $0x5, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x1, %edx
leaq 0x1854(%rip), %rcx      # 0xe1af
movl $0x6, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x3, %rax
je 0xc991
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
movl %eax, -0x28(%rbp)
subl $0x69, %eax
je 0xc9b1
jmp 0xc9a7
movl -0x28(%rbp), %eax
subl $0x6f, %eax
je 0xc9d9
jmp 0xca01
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x1, %edx
leaq 0x2a5c(%rip), %rcx      # 0xf422
movl $0xb, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x2, %esi
movl $0x1, %edx
leaq 0x22f3(%rip), %rcx      # 0xece1
movl $0x16, %r8d
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x2, %rax
je 0xca24
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
movl %eax, -0x2c(%rbp)
subl $0x66, %eax
je 0xca44
jmp 0xca3a
movl -0x2c(%rbp), %eax
subl $0x6e, %eax
je 0xca50
jmp 0xca5c
movl $0x7, -0x4(%rbp)
jmp 0xcae9
movl $0x8, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
cmpq $0x4, %rax
jge 0xca7c
jmp 0xcae2
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movsbl 0x1(%rax), %eax
movl %eax, -0x30(%rbp)
subl $0x72, %eax
je 0xca9c
jmp 0xca92
movl -0x30(%rbp), %eax
subl $0x79, %eax
je 0xcabe
jmp 0xcae0
movq -0x10(%rbp), %rdi
movl $0x2, %edx
leaq 0x2056(%rip), %rcx      # 0xeb02
movl $0xe, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
movq -0x10(%rbp), %rdi
movl $0x2, %edx
leaq 0x1972(%rip), %rcx      # 0xe440
movl $0xf, %r8d
movl %edx, %esi
callq 0xcb00
movl %eax, -0x4(%rbp)
jmp 0xcae9
jmp 0xcae2
movl $0x2f, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)