// File: /workspace/github_c_makefile_star2_O2/takoeight0821[P]hoc_nyan/src/parse.c
// Function: unary
static Node *unary() {
  Token *tok;
  if ((tok = match("sizeof"))) {
    if (!match("(")) {
      parse_error("(", peek(0));
    }
    Node *node;
    if (is_typename(peek(0))) {
      // sizeof(type)は計算してしまってNINTノードにする
      Type *type = type_specifier();
      while (match("*")) {
        type = ptr_to(type);
      }
      node = new_int_node(tok, size_of(type));
    } else {
      // sizeof(expr)はsemaで型付けしてemitで計算する
      node = new_node(NSIZEOF, tok);
      node->expr = unary();
    }
    if (!match(")")) {
      parse_error(")", peek(0));
    }
    return node;
  } else if (match("+")) {
    return cast();
  } else if ((tok = match("-"))) {
    Node *node = new_node(NSUB, tok);
    node->lhs = new_int_node(tok, 0);
    node->rhs = cast();
    return node;
  } else if ((tok = match("&"))) {
    Node *node = new_node(NADDR, tok);
    node->expr = cast();
    return node;
  } else if ((tok = match("*"))) {
    Node *node = new_node(NDEREF, tok);
    node->expr = cast();
    return node;
  } else if ((tok = match("!"))) {
    Node *node = new_node(NLOGNOT, tok);
    node->expr = cast();
    return node;
  } else if ((tok = match("~"))) {
    Node *node = new_node(NNOT, tok);
    node->expr = cast();
    return node;
  } else {
    Node *node = postfix();
    return node;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x4aba(%rip), %rdi      # 0xd2a1
callq 0x7967
testq %rax, %rax
je 0x8859
movq %rax, %rbx
leaq 0x5057(%rip), %rdi      # 0xd852
callq 0x7967
movq 0x9951(%rip), %rsi      # 0x12158
testq %rax, %rax
je 0x8d41
movq %rsi, %rdi
callq 0x876f
testl %eax, %eax
je 0x887d
callq 0x7db4
movq %rax, %r14
leaq 0x4ca4(%rip), %r15      # 0xd4cf
movq %r15, %rdi
callq 0x7967
movq %r14, %rdi
testq %rax, %rax
je 0x8845
callq 0x76a2
movq %rax, %r14
jmp 0x882b
callq 0x75fe
movq %rbx, %rdi
movl %eax, %esi
callq 0x8183
movq %rax, %rbx
jmp 0x8894
leaq 0x4a50(%rip), %rdi      # 0xd2b0
callq 0x7967
testq %rax, %rax
je 0x88bb
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x86b4
pushq $0x23
popq %rdi
movq %rbx, %rsi
callq 0x75dc
movq %rax, %rbx
callq 0x87d5
movq %rax, 0x38(%rbx)
leaq 0x4a57(%rip), %rdi      # 0xd2f2
callq 0x7967
testq %rax, %rax
je 0x8d14
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x49f1(%rip), %rdi      # 0xd2b3
callq 0x7967
testq %rax, %rax
je 0x88f6
movq %rax, %r14
pushq $0x4
popq %rdi
movq %rax, %rsi
callq 0x75dc
movq %rax, %rbx
movq %r14, %rdi
xorl %esi, %esi
callq 0x8183
movq %rax, 0x18(%rbx)
callq 0x86b4
movq %rax, 0x20(%rbx)
jmp 0x88a9
leaq 0x4998(%rip), %rdi      # 0xd295
callq 0x7967
testq %rax, %rax
je 0x890b
pushq $0x19
jmp 0x8948
leaq 0x4bbd(%rip), %rdi      # 0xd4cf
callq 0x7967
testq %rax, %rax
je 0x8920
pushq $0x1a
jmp 0x8948
leaq 0x4981(%rip), %rdi      # 0xd2a8
callq 0x7967
testq %rax, %rax
je 0x8935
pushq $0xe
jmp 0x8948
leaq 0x496e(%rip), %rdi      # 0xd2aa
callq 0x7967
testq %rax, %rax
je 0x8962
pushq $0xf
popq %rdi
movq %rax, %rsi
callq 0x75dc
movq %rax, %rbx
callq 0x86b4
movq %rax, 0x38(%rbx)
jmp 0x88a9
movq 0x97ef(%rip), %rdi      # 0x12158
leaq 0x4ee2(%rip), %rsi      # 0xd852
callq 0xab1d
testb %al, %al
je 0x8990
movq 0x97d8(%rip), %rax      # 0x12158
movq (%rax), %rdi
callq 0x876f
testl %eax, %eax
je 0x8b73
movq 0x97c1(%rip), %rbx      # 0x12158
movl 0x8(%rbx), %eax
cmpl $0x2, %eax
jne 0x89c0
movq (%rbx), %rdi
leaq 0x4ea9(%rip), %rsi      # 0xd852
callq 0xab1d
movq 0x97a3(%rip), %rbx      # 0x12158
testb %al, %al
je 0x8b32
movl 0x8(%rbx), %eax
cmpl $0x1, %eax
je 0x8a88
cmpl $0x2, %eax
jne 0x8b47
pushq $0x18
popq %rdi
movq %rbx, %rsi
callq 0x75dc
movq %rax, %rbx
movq 0x9771(%rip), %rax      # 0x12158
movq 0x10(%rax), %rax
movq %rax, 0x40(%rbx)
xorl %eax, %eax
callq 0x229c
movq %rax, 0x50(%rbx)
movq 0x9757(%rip), %rax      # 0x12158
movq (%rax), %rax
movq %rax, 0x974d(%rip)      # 0x12158
leaq 0x4e40(%rip), %rdi      # 0xd852
callq 0x7967
testq %rax, %rax
je 0x8d3a
leaq 0x48cb(%rip), %rdi      # 0xd2f2
callq 0x7967
testq %rax, %rax
jne 0x8ba1
leaq 0x48b6(%rip), %r14      # 0xd2f2
leaq 0x360b(%rip), %r15      # 0xc04e
movq 0x50(%rbx), %r12
callq 0x81f9
movq %r12, %rdi
movq %rax, %rsi
callq 0x22c6
movq %r14, %rdi
callq 0x7967
testq %rax, %rax
jne 0x8ba1
movq %r15, %rdi
callq 0x7967
testq %rax, %rax
jne 0x8a43
movq 0x96dc(%rip), %rsi      # 0x12158
leaq 0x35cb(%rip), %rdi      # 0xc04e
callq 0x7d21
leaq 0x4839(%rip), %rsi      # 0xd2c8
pushq $0x1
popq %rdi
callq 0x8160
movq 0x18(%rax), %r12
xorl %eax, %eax
callq 0x229c
movq %rax, %r14
movq 0x96dc(%rip), %rsi      # 0x12188
leaq 0x1(%rsi), %rax
movq %rax, 0x96d1(%rip)      # 0x12188
leaq 0x4811(%rip), %rdi      # 0xd2cf
xorl %eax, %eax
callq 0xa84a
movq %rax, %r15
movq %r12, %r13
movsbl (%r13), %esi
movq %rbx, %rdi
testl %esi, %esi
je 0x8aec
callq 0x8183
movq %r14, %rdi
movq %rax, %rsi
callq 0x22c6
incq %r13
jmp 0x8acb
xorl %esi, %esi
callq 0x8183
movq %r14, %rdi
movq %rax, %rsi
callq 0x22c6
callq 0x7681
movq %rax, %r13
movq %r12, %rdi
callq 0x2080
leaq 0x1(%rax), %rsi
movq %r13, %rdi
callq 0x76b7
movq %r15, %rdi
movq %rax, %rsi
xorl %edx, %edx
movq %r14, %rcx
callq 0x81ad
movq %rbx, %rdi
movq %r15, %rsi
jmp 0x8b3d
callq 0x8032
movq %rbx, %rdi
movq %rax, %rsi
callq 0x8d93
movq %rax, %rbx
jmp 0x8ba1
xorl %edi, %edi
movq %rbx, %rsi
callq 0x75dc
movq %rax, %rbx
leaq 0x4717(%rip), %rsi      # 0xd272
xorl %edi, %edi
callq 0x8160
movl 0xc(%rax), %eax
movl %eax, 0x28(%rbx)
callq 0x768c
movq %rax, 0x10(%rbx)
jmp 0x8ba1
movq 0x95de(%rip), %rax      # 0x12158
movq (%rax), %rax
movq %rax, 0x95d4(%rip)      # 0x12158
callq 0x8e75
movq %rax, %rbx
leaq 0x475f(%rip), %rdi      # 0xd2f2
callq 0x7967
testq %rax, %rax
je 0x8d14
leaq 0x474e(%rip), %r14      # 0xd2f6
pushq $0x1b
popq %r13
movq %r14, %rdi
callq 0x7967
testq %rax, %rax
je 0x8bdc
movq %rax, %r12
callq 0x8032
movq %rax, %rbp
movl %r13d, %edi
movq %r12, %rsi
callq 0x75dc
movq %rbx, 0x38(%rax)
movq %rbp, 0x40(%rax)
movq %rax, %rbx
jmp 0x8bac
leaq 0x46c9(%rip), %rdi      # 0xd2ac
callq 0x7967
testq %rax, %rax
je 0x8c22
movq %rax, %r12
callq 0x8032
movq %rax, %rbp
pushq $0x1a
popq %rdi
movq %r12, %rsi
callq 0x75dc
movq %rax, %r15
movq %rbx, 0x38(%rax)
movl %r13d, %edi
movq %r12, %rsi
callq 0x75dc
movq %rax, %rbx
movq %r15, 0x38(%rax)
movq %rbp, 0x40(%rax)
jmp 0x8bac
leaq 0x4647(%rip), %rdi      # 0xd270
callq 0x7967
testq %rax, %rax
je 0x8c69
movq %rax, %r12
callq 0x8e75
movq %rax, %rbp
leaq 0x4229(%rip), %rdi      # 0xce6e
callq 0x7967
testq %rax, %rax
je 0x8d27
movq %r12, %rdi
movq %rbx, %rsi
movq %rbp, %rdx
callq 0x8d4d
movq %rax, %rbx
jmp 0x8bac
leaq 0x463f(%rip), %rdi      # 0xd2af
callq 0x7967
testq %rax, %rax
je 0x8ca4
movq %rax, %r12
movq %rax, %rdi
pushq $0x1
popq %rsi
callq 0x8183
movq %rax, %r15
movq %r12, %rdi
pushq $0x3
popq %rsi
movq %rbx, %rdx
movq %rax, %rcx
callq 0x82a7
movq %rax, (%rsp)
pushq $0x4
jmp 0x8ce1
leaq 0x4607(%rip), %rdi      # 0xd2b2
callq 0x7967
testq %rax, %rax
je 0x88a9
movq %rax, %r12
movq %rax, %rdi
pushq $0x1
popq %rsi
callq 0x8183
movq %rax, %r15
movq %r12, %rdi
pushq $0x4
popq %rsi
movq %rbx, %rdx
movq %rax, %rcx
callq 0x82a7
movq %rax, (%rsp)
pushq $0x3
popq %rdi
movq %r12, %rsi
callq 0x75dc
movq %rax, %rbp
movq %rbx, 0x18(%rax)
movq %r15, 0x20(%rax)
pushq $0x15
popq %rdi
movq %r12, %rsi
callq 0x75dc
movq %rax, %rbx
movq (%rsp), %rax
movq %rax, 0x18(%rbx)
movq %rbp, 0x20(%rbx)
jmp 0x8bac
movq 0x943d(%rip), %rsi      # 0x12158
leaq 0x45d0(%rip), %rdi      # 0xd2f2
callq 0x7d21
movq 0x942a(%rip), %rsi      # 0x12158
leaq 0x4139(%rip), %rdi      # 0xce6e
callq 0x7d21
movq 0x9417(%rip), %rsi      # 0x12158
leaq 0x4b0a(%rip), %rdi      # 0xd852
callq 0x7d21