// File: /workspace/github_c_makefile_star2_O3/42Bastian[P]lyxass/parser.c
// Function: GetLine
int GetLine()
{
  extern int mac_mode;
  char *ptr;

  int last_ch = 0;

  srcLinePtr = ptr = srcLine;
  memset((char *)ptr,0,256);

  memset((char *)&Current.Label, 0, sizeof(label_t));

  while ( GetChar() ){

    if ( Current.Macro.Processing ){
      if ( (last_ch != '.') && (ch == '\\') ){
        if ( last_ch == '.' ){
          *ptr++ = '\\';
        }
        if ( next_ch >= '0' && next_ch <= '9' ){
          int var;
          GetChar();
          var = ch - '0';
          if ( mac_mode ){
            if ( --var < 0 ){
              var = 9;
            }
          }
          if ( (next_ch >= '0' && next_ch <= '5')){
            GetChar();
            var = 10*var + ch-'0';
          }
          ptr = InsertMacroVar(ptr,var);
          continue;

          //
          // insert number of parameters
          //
        }else if ( next_ch == '#' ){
          char help[20];
          char *ptr1 = help;

          GetChar();
          sprintf(help,"%d",Current.Macro.NPara);
          while ( *ptr1 ){
            *ptr++ = *ptr1++;
          }
          continue;

          //
          // insert macro-name
          //
        } else if ( (next_ch == '?' && !mac_mode) || next_ch == '^' ){
          char *ptr1 = Current.Macro.Name;
          GetChar();
          while ( *ptr1 ){
            *ptr++ = *ptr1++;
          }
          continue;
        } else if ( next_ch == '~' ){
          char *ptr1 = (char *)calloc(10,1);

          GetChar();
          if ( mac_mode ){
            *ptr++='M';
          }
          sprintf(ptr1,"%04X",Current.Macro.invoked);

          while(*ptr1)
            *ptr++=*ptr1++;
          continue;
        } else if ( mac_mode && next_ch == '?' ){
          int var;
          GetChar();
          GetChar();
          var = ch - '1';
          if ( var < 0 ) {
            var = 9;
          }
          if ( macrovars[Current.Macro.Processing-1][var][0] ){
            *ptr++ = '1';
          } else {
            *ptr++ = '0';
          }
          continue;
        }

      }
    }
    last_ch = ch;
    *ptr++ = ch;

  }

  if ( srcLinePtr[255] ) exit(1);

  if ( ch == EOF && ptr == srcLinePtr ){
    return 0;
  } else {
    GetAtom();
    return 1;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
leaq 0x181f8(%rip), %rbx     # 0x1ce20
movq %rbx, 0x182f1(%rip)     # 0x1cf20
movl $0x100, %edx            # imm = 0x100
movq %rbx, %rdi
xorl %esi, %esi
callq 0x30d0
xorps %xmm0, %xmm0
leaq 0xf9c0(%rip), %rbp      # 0x14608
movups %xmm0, 0x28(%rbp)
movups %xmm0, 0x38(%rbp)
movups %xmm0, 0x48(%rbp)
movups %xmm0, 0x58(%rbp)
movups %xmm0, 0x68(%rbp)
movups %xmm0, 0x78(%rbp)
callq 0x4b10
testl %eax, %eax
je 0x4ea7
leaq 0x181ac(%rip), %rbx     # 0x1ce20
leaq 0x18f35(%rip), %r12     # 0x1dbb0
leaq 0x1911e(%rip), %r15     # 0x1dda0
xorl %r13d, %r13d
movl %r13d, %r14d
cmpl $0x0, 0x8(%rbp)
movl 0x1817d(%rip), %r13d    # 0x1ce10
je 0x4e94
cmpl $0x2e, %r14d
je 0x4e94
cmpl $0x5c, %r13d
jne 0x4e94
movl 0x18161(%rip), %eax     # 0x1ce14
leal -0x30(%rax), %ecx
cmpl $0x9, %ecx
ja 0x4d56
callq 0x4b10
movl 0x18146(%rip), %eax     # 0x1ce10
leal -0x30(%rax), %ecx
leal -0x31(%rax), %r13d
cmpl $0x31, %eax
movl $0x9, %eax
cmovll %eax, %r13d
cmpl $0x0, (%r12)
cmovel %ecx, %r13d
movl 0x18128(%rip), %eax     # 0x1ce14
addl $-0x30, %eax
cmpl $0x5, %eax
ja 0x4d0c
callq 0x4b10
leal (%r13,%r13,4), %eax
movl 0x1810c(%rip), %ecx     # 0x1ce10
leal (%rcx,%rax,2), %r13d
addl $-0x30, %r13d
movslq 0x8(%rbp), %rax
leaq (%rax,%rax,4), %rcx
shlq $0x8, %rcx
movslq %r13d, %rax
leaq (%rax,%rax,4), %rdx
shlq $0x4, %rdx
leaq (%rcx,%r15), %rax
movb -0x500(%rdx,%rax), %al
testb %al, %al
je 0x4e85
addq %rdx, %rcx
addq %r15, %rcx
addq $-0x4ff, %rcx           # imm = 0xFB01
movb %al, (%rbx)
incq %rbx
movb (%rcx), %al
incq %rcx
testb %al, %al
jne 0x4d43
jmp 0x4e85
cmpl $0x23, %eax
jne 0x4d97
callq 0x4b10
movl 0x20(%rbp), %edx
movq %rsp, %rdi
leaq 0x8371(%rip), %rsi      # 0xd0de
xorl %eax, %eax
callq 0x31b0
movb (%rsp), %al
testb %al, %al
je 0x4e85
leaq 0x1(%rsp), %rcx
movb %al, (%rbx)
incq %rbx
movb (%rcx), %al
incq %rcx
testb %al, %al
jne 0x4d84
jmp 0x4e85
movl %eax, %edx
xorl $0x3f, %edx
movl (%r12), %ecx
orl %ecx, %edx
setne %dl
cmpl $0x5e, %eax
je 0x4e0c
testb %dl, %dl
je 0x4e0c
cmpl $0x7e, %eax
jne 0x4e32
movl $0xa, %edi
movl $0x1, %esi
callq 0x3100
movq %rax, %r13
callq 0x4b10
cmpl $0x0, (%r12)
je 0x4dd7
movb $0x4d, (%rbx)
incq %rbx
movl 0x24(%rbp), %edx
movq %r13, %rdi
leaq 0x82fd(%rip), %rsi      # 0xd0e1
xorl %eax, %eax
callq 0x31b0
movb (%r13), %al
testb %al, %al
je 0x4e85
incq %r13
movb %al, (%rbx)
incq %rbx
movb (%r13), %al
incq %r13
testb %al, %al
jne 0x4dfa
jmp 0x4e85
movq 0x18(%rbp), %r13
callq 0x4b10
movb (%r13), %al
testb %al, %al
je 0x4e85
incq %r13
movb %al, (%rbx)
incq %rbx
movb (%r13), %al
incq %r13
testb %al, %al
jne 0x4e20
jmp 0x4e85
cmpl $0x3f, %eax
jne 0x4e94
testl %ecx, %ecx
je 0x4e94
callq 0x4b10
callq 0x4b10
movl 0x17fc5(%rip), %eax     # 0x1ce10
leal -0x31(%rax), %ecx
cmpl $0x31, %eax
movl $0x9, %eax
cmovll %eax, %ecx
movslq 0x8(%rbp), %rax
leaq (%rax,%rax,4), %rax
shlq $0x8, %rax
movslq %ecx, %rcx
leaq (%rcx,%rcx,4), %rcx
shlq $0x4, %rcx
addq %r15, %rax
cmpb $0x0, -0x500(%rcx,%rax)
sete %al
xorb $0x31, %al
movb %al, (%rbx)
incq %rbx
callq 0x4b10
testl %eax, %eax
jne 0x4c88
jmp 0x4ea7
movb %r13b, (%rbx)
incq %rbx
callq 0x4b10
testl %eax, %eax
jne 0x4c85
movq 0x18072(%rip), %rcx     # 0x1cf20
cmpb $0x0, 0xff(%rcx)
jne 0x4f10
cmpl $-0x1, 0x17f52(%rip)    # 0x1ce10
jne 0x4ec7
xorl %eax, %eax
cmpq %rcx, %rbx
je 0x4f01
movl 0x18063(%rip), %eax     # 0x1cf30
movl %eax, 0x18061(%rip)     # 0x1cf34
leaq 0x1(%rcx), %rax
movq %rax, 0x18042(%rip)     # 0x1cf20
movsbl (%rcx), %edx
movl %edx, 0x18049(%rip)     # 0x1cf30
movsbl 0x1(%rcx), %eax
movl %eax, 0x18047(%rip)     # 0x1cf38
movl $0x1, %eax
testl %edx, %edx
jne 0x4f01
movq %rcx, 0x1801f(%rip)     # 0x1cf20
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %edi
callq 0x31c0