
/* std::__basic_file<char>::showmanyc() */

uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)

{
  undefined4 uVar1;
  int iVar2;
  uint uVar3;
  uint uVar4;
  undefined8 uVar5;
  undefined1 auStack_c0 [24];
  uint local_a8;
  int local_88;
  uint local_84;
  undefined4 local_20;
  undefined2 local_1c;
  uint local_18 [3];
  
  local_18[0] = 0;
  uVar1 = fd(this);
  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);
  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {
    local_20 = fd(this);
    local_1c = 1;
    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);
    if (0 < iVar2) {
      uVar1 = fd(this);
      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);
      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {
        uVar1 = fd(this);
        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);
        uVar4 = local_84 - (int)uVar5;
        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);
        if (0 < (int)(uVar3 - (local_84 < uVar4))) {
          return 0x7fffffff;
        }
        if (uVar3 != local_84 < uVar4) {
          return uVar4;
        }
        if (uVar4 < 0x80000000) {
          return uVar4;
        }
        return 0x7fffffff;
      }
    }
    local_18[0] = 0;
  }
  return local_18[0];
}



/* std::__basic_file<char>::showmanyc() */

uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)

{
  undefined4 uVar1;
  int iVar2;
  uint uVar3;
  uint uVar4;
  undefined8 uVar5;
  undefined1 auStack_c0 [24];
  uint local_a8;
  int local_88;
  uint local_84;
  undefined4 local_20;
  undefined2 local_1c;
  uint local_18 [3];
  
  local_18[0] = 0;
  uVar1 = fd(this);
  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);
  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {
    local_20 = fd(this);
    local_1c = 1;
    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);
    if (0 < iVar2) {
      uVar1 = fd(this);
      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);
      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {
        uVar1 = fd(this);
        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);
        uVar4 = local_84 - (int)uVar5;
        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);
        if (0 < (int)(uVar3 - (local_84 < uVar4))) {
          return 0x7fffffff;
        }
        if (uVar3 != local_84 < uVar4) {
          return uVar4;
        }
        if (uVar4 < 0x80000000) {
          return uVar4;
        }
        return 0x7fffffff;
      }
    }
    local_18[0] = 0;
  }
  return local_18[0];
}


lui gp,0x19
addiu gp,gp,0x75a8
addu gp,gp,t9
addiu sp,sp,-0xe0
lw t9,-0x40cc(gp)
sw gp,0x18(sp)
sw ra,0xdc(sp)
sw s0,0xd4(sp)
or s0,a0,zero
sw s1,0xd8(sp)
bal 0x0033190c
_sw zero,0xc8(sp)
addiu a2,sp,0xc8
lw gp,0x18(sp)
li a1,0x467f
lw t9,-0x3658(gp)
jalr t9
_or a0,v0,zero
bne v0,zero,0x00331cf4
_lw gp,0x18(sp)
lw v0,0xc8(sp)
bgez v0,0x00331d74
_lw ra,0xdc(sp)
lw t9,-0x40cc(gp)
bal 0x0033190c
_or a0,s0,zero
or a2,zero,zero
lw gp,0x18(sp)
li a1,0x1
sw v0,0xc0(sp)
li v0,0x1
addiu a0,sp,0xc0
lw t9,-0x373c(gp)
jalr t9
_sh v0,0xc4(sp)
blez v0,0x00331d6c
_lw gp,0x18(sp)
lw t9,-0x40cc(gp)
bal 0x0033190c
_or a0,s0,zero
addiu a2,sp,0x20
lw gp,0x18(sp)
li a0,0x3
lw t9,-0x3764(gp)
jalr t9
_or a1,v0,zero
bne v0,zero,0x00331d6c
_lw gp,0x18(sp)
lw v0,0x38(sp)
ori v1,zero,0x8000
andi v0,v0,0xf000
beq v0,v1,0x00331d84
_lw t9,-0x40cc(gp)
or v0,zero,zero
lw ra,0xdc(sp)
lw s1,0xd8(sp)
lw s0,0xd4(sp)
jr ra
_addiu sp,sp,0xe0
or a0,s0,zero
lw s1,0x5c(sp)
bal 0x0033190c
_lw s0,0x58(sp)
or a3,zero,zero
lw gp,0x18(sp)
or a0,v0,zero
li v0,0x1
or a2,zero,zero
lw t9,-0x35d4(gp)
jalr t9
_sw v0,0x10(sp)
subu v1,s1,v1
subu v0,s0,v0
sltu a0,s1,v1
subu a0,v0,a0
blez a0,0x00331dd8
_or v0,v1,zero
lui v0,0x7fff
b 0x00331d70
_ori v0,v0,0xffff
bne a0,zero,0x00331d74
_lw ra,0xdc(sp)
lui v1,0x8000
sltu v1,v0,v1
bne v1,zero,0x00331d78
_lw s1,0xd8(sp)
lui v0,0x7fff
b 0x00331d74
_ori v0,v0,0xffff
(translation_unit "/* std::__basic_file<char>::showmanyc() */\n\nuint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}\n\n" comment (function_definition "uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::__basic_file<char>::" identifier : : identifier < primitive_type > : :) (function_declarator "showmanyc(__basic_file<char> *this)" identifier (parameter_list "(__basic_file<char> *this)" ( (parameter_declaration "__basic_file<char> *this" type_identifier (ERROR "<char>" < primitive_type >) (pointer_declarator "*this" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined1 auStack_c0 [24];" type_identifier (array_declarator "auStack_c0 [24]" identifier [ number_literal ]) ;) (declaration "uint local_a8;" type_identifier identifier ;) (declaration "int local_88;" primitive_type identifier ;) (declaration "uint local_84;" type_identifier identifier ;) (declaration "undefined4 local_20;" type_identifier identifier ;) (declaration "undefined2 local_1c;" type_identifier identifier ;) (declaration "uint local_18 [3];" type_identifier (array_declarator "local_18 [3]" identifier [ number_literal ]) ;) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);" (assignment_expression "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" identifier = (call_expression "(*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" (parenthesized_expression "(*(code *)PTR_ioctl_004c5be8)" ( (pointer_expression "*(code *)PTR_ioctl_004c5be8" * (cast_expression "(code *)PTR_ioctl_004c5be8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1,0x467f,local_18)" ( identifier , number_literal , identifier )))) ;) (if_statement "if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" if (parenthesized_expression "((iVar2 != 0) || ((int)local_18[0] < 0))" ( (binary_expression "(iVar2 != 0) || ((int)local_18[0] < 0)" (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) || (parenthesized_expression "((int)local_18[0] < 0)" ( (binary_expression "(int)local_18[0] < 0" (cast_expression "(int)local_18[0]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "local_18[0]" identifier [ number_literal ])) < number_literal) ))) )) (compound_statement "{\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" { (expression_statement "local_20 = fd(this);" (assignment_expression "local_20 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "local_1c = 1;" (assignment_expression "local_1c = 1" identifier = number_literal) ;) (expression_statement "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);" (assignment_expression "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0)" identifier = (call_expression "(*(code *)PTR_poll_004c5b04)(&local_20,1,0)" (parenthesized_expression "(*(code *)PTR_poll_004c5b04)" ( (pointer_expression "*(code *)PTR_poll_004c5b04" * (cast_expression "(code *)PTR_poll_004c5b04" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(&local_20,1,0)" ( (pointer_expression "&local_20" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" if (parenthesized_expression "(0 < iVar2)" ( (binary_expression "0 < iVar2" number_literal < identifier) )) (compound_statement "{\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);" (assignment_expression "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" identifier = (call_expression "(*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" (parenthesized_expression "(*(code *)PTR___fxstat64_004c5adc)" ( (pointer_expression "*(code *)PTR___fxstat64_004c5adc" * (cast_expression "(code *)PTR___fxstat64_004c5adc" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(3,uVar1,auStack_c0)" ( number_literal , identifier , identifier )))) ;) (if_statement "if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" if (parenthesized_expression "((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000))" ( (binary_expression "(iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)" (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) && (parenthesized_expression "((local_a8 & 0xf000) == 0x8000)" ( (binary_expression "(local_a8 & 0xf000) == 0x8000" (parenthesized_expression "(local_a8 & 0xf000)" ( (binary_expression "local_a8 & 0xf000" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);" (assignment_expression "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1)" identifier = (call_expression "(*(code *)PTR_lseek64_004c5c6c)(uVar1)" (parenthesized_expression "(*(code *)PTR_lseek64_004c5c6c)" ( (pointer_expression "*(code *)PTR_lseek64_004c5c6c" * (cast_expression "(code *)PTR_lseek64_004c5c6c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier )))) ;) (expression_statement "uVar4 = local_84 - (int)uVar5;" (assignment_expression "uVar4 = local_84 - (int)uVar5" identifier = (binary_expression "local_84 - (int)uVar5" identifier - (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);" (assignment_expression "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier = (binary_expression "local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier - (cast_expression "(int)((ulonglong)uVar5 >> 0x20)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" ( (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) ))))) ;) (if_statement "if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }" if (parenthesized_expression "(0 < (int)(uVar3 - (local_84 < uVar4)))" ( (binary_expression "0 < (int)(uVar3 - (local_84 < uVar4))" number_literal < (cast_expression "(int)(uVar3 - (local_84 < uVar4))" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(uVar3 - (local_84 < uVar4))" ( (binary_expression "uVar3 - (local_84 < uVar4)" identifier - (parenthesized_expression "(local_84 < uVar4)" ( (binary_expression "local_84 < uVar4" identifier < identifier) ))) )))) )) (compound_statement "{\n          return 0x7fffffff;\n        }" { (return_statement "return 0x7fffffff;" return number_literal ;) })) (if_statement "if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar3 != local_84 < uVar4)" ( (binary_expression "uVar3 != local_84 < uVar4" identifier != (binary_expression "local_84 < uVar4" identifier < identifier)) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (if_statement "if (uVar4 < 0x80000000) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar4 < 0x80000000)" ( (binary_expression "uVar4 < 0x80000000" identifier < number_literal) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (return_statement "return 0x7fffffff;" return number_literal ;) })) })) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return local_18[0];" return (subscript_expression "local_18[0]" identifier [ number_literal ]) ;) })))
(translation_unit "/* std::__basic_file<char>::showmanyc() */\n\nuint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}\n\n" comment (function_definition "uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::__basic_file<char>::" identifier : : identifier < primitive_type > : :) (function_declarator "showmanyc(__basic_file<char> *this)" identifier (parameter_list "(__basic_file<char> *this)" ( (parameter_declaration "__basic_file<char> *this" type_identifier (ERROR "<char>" < primitive_type >) (pointer_declarator "*this" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined1 auStack_c0 [24];" type_identifier (array_declarator "auStack_c0 [24]" identifier [ number_literal ]) ;) (declaration "uint local_a8;" type_identifier identifier ;) (declaration "int local_88;" primitive_type identifier ;) (declaration "uint local_84;" type_identifier identifier ;) (declaration "undefined4 local_20;" type_identifier identifier ;) (declaration "undefined2 local_1c;" type_identifier identifier ;) (declaration "uint local_18 [3];" type_identifier (array_declarator "local_18 [3]" identifier [ number_literal ]) ;) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);" (assignment_expression "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" identifier = (call_expression "(*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" (parenthesized_expression "(*(code *)PTR_ioctl_004c5be8)" ( (pointer_expression "*(code *)PTR_ioctl_004c5be8" * (cast_expression "(code *)PTR_ioctl_004c5be8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1,0x467f,local_18)" ( identifier , number_literal , identifier )))) ;) (if_statement "if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" if (parenthesized_expression "((iVar2 != 0) || ((int)local_18[0] < 0))" ( (binary_expression "(iVar2 != 0) || ((int)local_18[0] < 0)" (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) || (parenthesized_expression "((int)local_18[0] < 0)" ( (binary_expression "(int)local_18[0] < 0" (cast_expression "(int)local_18[0]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "local_18[0]" identifier [ number_literal ])) < number_literal) ))) )) (compound_statement "{\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" { (expression_statement "local_20 = fd(this);" (assignment_expression "local_20 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "local_1c = 1;" (assignment_expression "local_1c = 1" identifier = number_literal) ;) (expression_statement "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);" (assignment_expression "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0)" identifier = (call_expression "(*(code *)PTR_poll_004c5b04)(&local_20,1,0)" (parenthesized_expression "(*(code *)PTR_poll_004c5b04)" ( (pointer_expression "*(code *)PTR_poll_004c5b04" * (cast_expression "(code *)PTR_poll_004c5b04" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(&local_20,1,0)" ( (pointer_expression "&local_20" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" if (parenthesized_expression "(0 < iVar2)" ( (binary_expression "0 < iVar2" number_literal < identifier) )) (compound_statement "{\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);" (assignment_expression "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" identifier = (call_expression "(*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" (parenthesized_expression "(*(code *)PTR___fxstat64_004c5adc)" ( (pointer_expression "*(code *)PTR___fxstat64_004c5adc" * (cast_expression "(code *)PTR___fxstat64_004c5adc" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(3,uVar1,auStack_c0)" ( number_literal , identifier , identifier )))) ;) (if_statement "if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" if (parenthesized_expression "((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000))" ( (binary_expression "(iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)" (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) && (parenthesized_expression "((local_a8 & 0xf000) == 0x8000)" ( (binary_expression "(local_a8 & 0xf000) == 0x8000" (parenthesized_expression "(local_a8 & 0xf000)" ( (binary_expression "local_a8 & 0xf000" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);" (assignment_expression "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1)" identifier = (call_expression "(*(code *)PTR_lseek64_004c5c6c)(uVar1)" (parenthesized_expression "(*(code *)PTR_lseek64_004c5c6c)" ( (pointer_expression "*(code *)PTR_lseek64_004c5c6c" * (cast_expression "(code *)PTR_lseek64_004c5c6c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier )))) ;) (expression_statement "uVar4 = local_84 - (int)uVar5;" (assignment_expression "uVar4 = local_84 - (int)uVar5" identifier = (binary_expression "local_84 - (int)uVar5" identifier - (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);" (assignment_expression "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier = (binary_expression "local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier - (cast_expression "(int)((ulonglong)uVar5 >> 0x20)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" ( (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) ))))) ;) (if_statement "if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }" if (parenthesized_expression "(0 < (int)(uVar3 - (local_84 < uVar4)))" ( (binary_expression "0 < (int)(uVar3 - (local_84 < uVar4))" number_literal < (cast_expression "(int)(uVar3 - (local_84 < uVar4))" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(uVar3 - (local_84 < uVar4))" ( (binary_expression "uVar3 - (local_84 < uVar4)" identifier - (parenthesized_expression "(local_84 < uVar4)" ( (binary_expression "local_84 < uVar4" identifier < identifier) ))) )))) )) (compound_statement "{\n          return 0x7fffffff;\n        }" { (return_statement "return 0x7fffffff;" return number_literal ;) })) (if_statement "if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar3 != local_84 < uVar4)" ( (binary_expression "uVar3 != local_84 < uVar4" identifier != (binary_expression "local_84 < uVar4" identifier < identifier)) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (if_statement "if (uVar4 < 0x80000000) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar4 < 0x80000000)" ( (binary_expression "uVar4 < 0x80000000" identifier < number_literal) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (return_statement "return 0x7fffffff;" return number_literal ;) })) })) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return local_18[0];" return (subscript_expression "local_18[0]" identifier [ number_literal ]) ;) })))
(translation_unit "uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}\n\n" (function_definition "uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::__basic_file<char>::" identifier : : identifier < primitive_type > : :) (function_declarator "showmanyc(__basic_file<char> *this)" identifier (parameter_list "(__basic_file<char> *this)" ( (parameter_declaration "__basic_file<char> *this" type_identifier (ERROR "<char>" < primitive_type >) (pointer_declarator "*this" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined1 auStack_c0 [24];" type_identifier (array_declarator "auStack_c0 [24]" identifier [ number_literal ]) ;) (declaration "uint local_a8;" type_identifier identifier ;) (declaration "int local_88;" primitive_type identifier ;) (declaration "uint local_84;" type_identifier identifier ;) (declaration "undefined4 local_20;" type_identifier identifier ;) (declaration "undefined2 local_1c;" type_identifier identifier ;) (declaration "uint local_18 [3];" type_identifier (array_declarator "local_18 [3]" identifier [ number_literal ]) ;) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);" (assignment_expression "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" identifier = (call_expression "(*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" (parenthesized_expression "(*(code *)PTR_ioctl_004c5be8)" ( (pointer_expression "*(code *)PTR_ioctl_004c5be8" * (cast_expression "(code *)PTR_ioctl_004c5be8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1,0x467f,local_18)" ( identifier , number_literal , identifier )))) ;) (if_statement "if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" if (parenthesized_expression "((iVar2 != 0) || ((int)local_18[0] < 0))" ( (binary_expression "(iVar2 != 0) || ((int)local_18[0] < 0)" (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) || (parenthesized_expression "((int)local_18[0] < 0)" ( (binary_expression "(int)local_18[0] < 0" (cast_expression "(int)local_18[0]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "local_18[0]" identifier [ number_literal ])) < number_literal) ))) )) (compound_statement "{\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" { (expression_statement "local_20 = fd(this);" (assignment_expression "local_20 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "local_1c = 1;" (assignment_expression "local_1c = 1" identifier = number_literal) ;) (expression_statement "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);" (assignment_expression "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0)" identifier = (call_expression "(*(code *)PTR_poll_004c5b04)(&local_20,1,0)" (parenthesized_expression "(*(code *)PTR_poll_004c5b04)" ( (pointer_expression "*(code *)PTR_poll_004c5b04" * (cast_expression "(code *)PTR_poll_004c5b04" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(&local_20,1,0)" ( (pointer_expression "&local_20" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" if (parenthesized_expression "(0 < iVar2)" ( (binary_expression "0 < iVar2" number_literal < identifier) )) (compound_statement "{\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);" (assignment_expression "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" identifier = (call_expression "(*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" (parenthesized_expression "(*(code *)PTR___fxstat64_004c5adc)" ( (pointer_expression "*(code *)PTR___fxstat64_004c5adc" * (cast_expression "(code *)PTR___fxstat64_004c5adc" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(3,uVar1,auStack_c0)" ( number_literal , identifier , identifier )))) ;) (if_statement "if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" if (parenthesized_expression "((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000))" ( (binary_expression "(iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)" (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) && (parenthesized_expression "((local_a8 & 0xf000) == 0x8000)" ( (binary_expression "(local_a8 & 0xf000) == 0x8000" (parenthesized_expression "(local_a8 & 0xf000)" ( (binary_expression "local_a8 & 0xf000" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" { (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" identifier = (call_expression "fd(this)" identifier (argument_list "(this)" ( identifier )))) ;) (expression_statement "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);" (assignment_expression "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1)" identifier = (call_expression "(*(code *)PTR_lseek64_004c5c6c)(uVar1)" (parenthesized_expression "(*(code *)PTR_lseek64_004c5c6c)" ( (pointer_expression "*(code *)PTR_lseek64_004c5c6c" * (cast_expression "(code *)PTR_lseek64_004c5c6c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier )))) ;) (expression_statement "uVar4 = local_84 - (int)uVar5;" (assignment_expression "uVar4 = local_84 - (int)uVar5" identifier = (binary_expression "local_84 - (int)uVar5" identifier - (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);" (assignment_expression "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier = (binary_expression "local_88 - (int)((ulonglong)uVar5 >> 0x20)" identifier - (cast_expression "(int)((ulonglong)uVar5 >> 0x20)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" ( (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) ))))) ;) (if_statement "if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }" if (parenthesized_expression "(0 < (int)(uVar3 - (local_84 < uVar4)))" ( (binary_expression "0 < (int)(uVar3 - (local_84 < uVar4))" number_literal < (cast_expression "(int)(uVar3 - (local_84 < uVar4))" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(uVar3 - (local_84 < uVar4))" ( (binary_expression "uVar3 - (local_84 < uVar4)" identifier - (parenthesized_expression "(local_84 < uVar4)" ( (binary_expression "local_84 < uVar4" identifier < identifier) ))) )))) )) (compound_statement "{\n          return 0x7fffffff;\n        }" { (return_statement "return 0x7fffffff;" return number_literal ;) })) (if_statement "if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar3 != local_84 < uVar4)" ( (binary_expression "uVar3 != local_84 < uVar4" identifier != (binary_expression "local_84 < uVar4" identifier < identifier)) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (if_statement "if (uVar4 < 0x80000000) {\n          return uVar4;\n        }" if (parenthesized_expression "(uVar4 < 0x80000000)" ( (binary_expression "uVar4 < 0x80000000" identifier < number_literal) )) (compound_statement "{\n          return uVar4;\n        }" { (return_statement "return uVar4;" return identifier ;) })) (return_statement "return 0x7fffffff;" return number_literal ;) })) })) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return local_18[0];" return (subscript_expression "local_18[0]" identifier [ number_literal ]) ;) })))
(translation_unit (function_definition TYPE (ms_call_modifier __thiscall) (ERROR IDENT : : IDENT < TYPE > : :) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (ERROR < TYPE >) (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , LIT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ])) < LIT) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression & IDENT) , LIT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( LIT , IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == LIT) )) && (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT - (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT - (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT - (parenthesized_expression ( (binary_expression IDENT < IDENT) ))) )))) )) (compound_statement { (return_statement return LIT ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (binary_expression IDENT < IDENT)) )) (compound_statement { (return_statement return IDENT ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (return_statement return IDENT ;) })) (return_statement return LIT ;) })) })) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) })) (return_statement return (subscript_expression IDENT [ LIT ]) ;) })))
(function_definition "uint __thiscall std::__basic_file<char>::showmanyc(__basic_file<char> *this)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" (type_identifier "uint") (ms_call_modifier "__thiscall" (__thiscall "__thiscall")) (ERROR "std::__basic_file<char>::" (identifier "std") (: ":") (: ":") (identifier "__basic_file") (< "<") (primitive_type "char") (> ">") (: ":") (: ":")) (function_declarator "showmanyc(__basic_file<char> *this)" (identifier "showmanyc") (parameter_list "(__basic_file<char> *this)" (( "(") (parameter_declaration "__basic_file<char> *this" (type_identifier "__basic_file") (ERROR "<char>" (< "<") (primitive_type "char") (> ">")) (pointer_declarator "*this" (* "*") (identifier "this"))) () ")"))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  uint uVar3;\n  uint uVar4;\n  undefined8 uVar5;\n  undefined1 auStack_c0 [24];\n  uint local_a8;\n  int local_88;\n  uint local_84;\n  undefined4 local_20;\n  undefined2 local_1c;\n  uint local_18 [3];\n  \n  local_18[0] = 0;\n  uVar1 = fd(this);\n  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);\n  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }\n  return local_18[0];\n}" ({ "{") (declaration "undefined4 uVar1;" (type_identifier "undefined4") (identifier "uVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "uint uVar3;" (type_identifier "uint") (identifier "uVar3") (; ";")) (declaration "uint uVar4;" (type_identifier "uint") (identifier "uVar4") (; ";")) (declaration "undefined8 uVar5;" (type_identifier "undefined8") (identifier "uVar5") (; ";")) (declaration "undefined1 auStack_c0 [24];" (type_identifier "undefined1") (array_declarator "auStack_c0 [24]" (identifier "auStack_c0") ([ "[") (number_literal "24") (] "]")) (; ";")) (declaration "uint local_a8;" (type_identifier "uint") (identifier "local_a8") (; ";")) (declaration "int local_88;" (primitive_type "int") (identifier "local_88") (; ";")) (declaration "uint local_84;" (type_identifier "uint") (identifier "local_84") (; ";")) (declaration "undefined4 local_20;" (type_identifier "undefined4") (identifier "local_20") (; ";")) (declaration "undefined2 local_1c;" (type_identifier "undefined2") (identifier "local_1c") (; ";")) (declaration "uint local_18 [3];" (type_identifier "uint") (array_declarator "local_18 [3]" (identifier "local_18") ([ "[") (number_literal "3") (] "]")) (; ";")) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" (identifier "local_18") ([ "[") (number_literal "0") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" (identifier "uVar1") (= "=") (call_expression "fd(this)" (identifier "fd") (argument_list "(this)" (( "(") (identifier "this") () ")")))) (; ";")) (expression_statement "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);" (assignment_expression "iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18)" (parenthesized_expression "(*(code *)PTR_ioctl_004c5be8)" (( "(") (pointer_expression "*(code *)PTR_ioctl_004c5be8" (* "*") (cast_expression "(code *)PTR_ioctl_004c5be8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_ioctl_004c5be8"))) () ")")) (argument_list "(uVar1,0x467f,local_18)" (( "(") (identifier "uVar1") (, ",") (number_literal "0x467f") (, ",") (identifier "local_18") () ")")))) (; ";")) (if_statement "if ((iVar2 != 0) || ((int)local_18[0] < 0)) {\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" (if "if") (parenthesized_expression "((iVar2 != 0) || ((int)local_18[0] < 0))" (( "(") (binary_expression "(iVar2 != 0) || ((int)local_18[0] < 0)" (parenthesized_expression "(iVar2 != 0)" (( "(") (binary_expression "iVar2 != 0" (identifier "iVar2") (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "((int)local_18[0] < 0)" (( "(") (binary_expression "(int)local_18[0] < 0" (cast_expression "(int)local_18[0]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "local_18[0]" (identifier "local_18") ([ "[") (number_literal "0") (] "]"))) (< "<") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n    local_20 = fd(this);\n    local_1c = 1;\n    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);\n    if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }\n    local_18[0] = 0;\n  }" ({ "{") (expression_statement "local_20 = fd(this);" (assignment_expression "local_20 = fd(this)" (identifier "local_20") (= "=") (call_expression "fd(this)" (identifier "fd") (argument_list "(this)" (( "(") (identifier "this") () ")")))) (; ";")) (expression_statement "local_1c = 1;" (assignment_expression "local_1c = 1" (identifier "local_1c") (= "=") (number_literal "1")) (; ";")) (expression_statement "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);" (assignment_expression "iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_poll_004c5b04)(&local_20,1,0)" (parenthesized_expression "(*(code *)PTR_poll_004c5b04)" (( "(") (pointer_expression "*(code *)PTR_poll_004c5b04" (* "*") (cast_expression "(code *)PTR_poll_004c5b04" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_poll_004c5b04"))) () ")")) (argument_list "(&local_20,1,0)" (( "(") (pointer_expression "&local_20" (& "&") (identifier "local_20")) (, ",") (number_literal "1") (, ",") (number_literal "0") () ")")))) (; ";")) (if_statement "if (0 < iVar2) {\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" (if "if") (parenthesized_expression "(0 < iVar2)" (( "(") (binary_expression "0 < iVar2" (number_literal "0") (< "<") (identifier "iVar2")) () ")")) (compound_statement "{\n      uVar1 = fd(this);\n      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);\n      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }\n    }" ({ "{") (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" (identifier "uVar1") (= "=") (call_expression "fd(this)" (identifier "fd") (argument_list "(this)" (( "(") (identifier "this") () ")")))) (; ";")) (expression_statement "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);" (assignment_expression "iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0)" (parenthesized_expression "(*(code *)PTR___fxstat64_004c5adc)" (( "(") (pointer_expression "*(code *)PTR___fxstat64_004c5adc" (* "*") (cast_expression "(code *)PTR___fxstat64_004c5adc" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___fxstat64_004c5adc"))) () ")")) (argument_list "(3,uVar1,auStack_c0)" (( "(") (number_literal "3") (, ",") (identifier "uVar1") (, ",") (identifier "auStack_c0") () ")")))) (; ";")) (if_statement "if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" (if "if") (parenthesized_expression "((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000))" (( "(") (binary_expression "(iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)" (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "((local_a8 & 0xf000) == 0x8000)" (( "(") (binary_expression "(local_a8 & 0xf000) == 0x8000" (parenthesized_expression "(local_a8 & 0xf000)" (( "(") (binary_expression "local_a8 & 0xf000" (identifier "local_a8") (& "&") (number_literal "0xf000")) () ")")) (== "==") (number_literal "0x8000")) () ")"))) () ")")) (compound_statement "{\n        uVar1 = fd(this);\n        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);\n        uVar4 = local_84 - (int)uVar5;\n        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);\n        if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }\n        if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }\n        if (uVar4 < 0x80000000) {\n          return uVar4;\n        }\n        return 0x7fffffff;\n      }" ({ "{") (expression_statement "uVar1 = fd(this);" (assignment_expression "uVar1 = fd(this)" (identifier "uVar1") (= "=") (call_expression "fd(this)" (identifier "fd") (argument_list "(this)" (( "(") (identifier "this") () ")")))) (; ";")) (expression_statement "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);" (assignment_expression "uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1)" (identifier "uVar5") (= "=") (call_expression "(*(code *)PTR_lseek64_004c5c6c)(uVar1)" (parenthesized_expression "(*(code *)PTR_lseek64_004c5c6c)" (( "(") (pointer_expression "*(code *)PTR_lseek64_004c5c6c" (* "*") (cast_expression "(code *)PTR_lseek64_004c5c6c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_lseek64_004c5c6c"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")")))) (; ";")) (expression_statement "uVar4 = local_84 - (int)uVar5;" (assignment_expression "uVar4 = local_84 - (int)uVar5" (identifier "uVar4") (= "=") (binary_expression "local_84 - (int)uVar5" (identifier "local_84") (- "-") (cast_expression "(int)uVar5" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar5")))) (; ";")) (expression_statement "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);" (assignment_expression "uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20)" (identifier "uVar3") (= "=") (binary_expression "local_88 - (int)((ulonglong)uVar5 >> 0x20)" (identifier "local_88") (- "-") (cast_expression "(int)((ulonglong)uVar5 >> 0x20)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" (( "(") (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" (( "(") (type_descriptor "ulonglong" (type_identifier "ulonglong")) () ")") (identifier "uVar5")) (>> ">>") (number_literal "0x20")) () ")"))))) (; ";")) (if_statement "if (0 < (int)(uVar3 - (local_84 < uVar4))) {\n          return 0x7fffffff;\n        }" (if "if") (parenthesized_expression "(0 < (int)(uVar3 - (local_84 < uVar4)))" (( "(") (binary_expression "0 < (int)(uVar3 - (local_84 < uVar4))" (number_literal "0") (< "<") (cast_expression "(int)(uVar3 - (local_84 < uVar4))" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(uVar3 - (local_84 < uVar4))" (( "(") (binary_expression "uVar3 - (local_84 < uVar4)" (identifier "uVar3") (- "-") (parenthesized_expression "(local_84 < uVar4)" (( "(") (binary_expression "local_84 < uVar4" (identifier "local_84") (< "<") (identifier "uVar4")) () ")"))) () ")")))) () ")")) (compound_statement "{\n          return 0x7fffffff;\n        }" ({ "{") (return_statement "return 0x7fffffff;" (return "return") (number_literal "0x7fffffff") (; ";")) (} "}"))) (if_statement "if (uVar3 != local_84 < uVar4) {\n          return uVar4;\n        }" (if "if") (parenthesized_expression "(uVar3 != local_84 < uVar4)" (( "(") (binary_expression "uVar3 != local_84 < uVar4" (identifier "uVar3") (!= "!=") (binary_expression "local_84 < uVar4" (identifier "local_84") (< "<") (identifier "uVar4"))) () ")")) (compound_statement "{\n          return uVar4;\n        }" ({ "{") (return_statement "return uVar4;" (return "return") (identifier "uVar4") (; ";")) (} "}"))) (if_statement "if (uVar4 < 0x80000000) {\n          return uVar4;\n        }" (if "if") (parenthesized_expression "(uVar4 < 0x80000000)" (( "(") (binary_expression "uVar4 < 0x80000000" (identifier "uVar4") (< "<") (number_literal "0x80000000")) () ")")) (compound_statement "{\n          return uVar4;\n        }" ({ "{") (return_statement "return uVar4;" (return "return") (identifier "uVar4") (; ";")) (} "}"))) (return_statement "return 0x7fffffff;" (return "return") (number_literal "0x7fffffff") (; ";")) (} "}"))) (} "}"))) (expression_statement "local_18[0] = 0;" (assignment_expression "local_18[0] = 0" (subscript_expression "local_18[0]" (identifier "local_18") ([ "[") (number_literal "0") (] "]")) (= "=") (number_literal "0")) (; ";")) (} "}"))) (return_statement "return local_18[0];" (return "return") (subscript_expression "local_18[0]" (identifier "local_18") ([ "[") (number_literal "0") (] "]")) (; ";")) (} "}")))

/* std::__basic_file<char>::showmanyc() */

type_1 __thiscall std::type_2<char>::function_1(type_2<char> *this)

{
  type_3 uVar1;
  int var_2;
  type_1 var_6;
  type_1 var_7;
  type_4 uVar5;
  type_5 auStack_c0 [24];
  type_1 var_3;
  int var_5;
  type_1 var_4;
  type_3 local_20;
  type_6 local_1c;
  type_1 local_18 [3];
  
  local_18[0] = 0;
  uVar1 = var_1(this);
  var_2 = (*(type_7 *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);
  if ((var_2 != 0) || ((int)local_18[0] < 0)) {
    local_20 = var_1(this);
    local_1c = 1;
    var_2 = (*(type_7 *)PTR_poll_004c5b04)(&local_20,1,0);
    if (0 < var_2) {
      uVar1 = var_1(this);
      var_2 = (*(type_7 *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);
      if ((var_2 == 0) && ((var_3 & 0xf000) == 0x8000)) {
        uVar1 = var_1(this);
        uVar5 = (*(type_7 *)PTR_lseek64_004c5c6c)(uVar1);
        var_7 = var_4 - (int)uVar5;
        var_6 = var_5 - (int)((type_8)uVar5 >> 0x20);
        if (0 < (int)(var_6 - (var_4 < var_7))) {
          return 0x7fffffff;
        }
        if (var_6 != var_4 < var_7) {
          return var_7;
        }
        if (var_7 < 0x80000000) {
          return var_7;
        }
        return 0x7fffffff;
      }
    }
    local_18[0] = 0;
  }
  return local_18[0];
}


(translation_unit (function_definition type: (type_identifier) (ms_call_modifier) (ERROR (identifier) (identifier) (primitive_type)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) (ERROR (primitive_type)) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (identifier) (number_literal) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (number_literal))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (pointer_expression argument: (identifier)) (number_literal) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (number_literal) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (number_literal) (identifier) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (number_literal) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (identifier) right: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))))))) consequence: (compound_statement (return_statement (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) consequence: (compound_statement (return_statement (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (identifier)))) (return_statement (number_literal)))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))))) (return_statement (subscript_expression argument: (identifier) index: (number_literal))))))

/* std::__basic_file<char>::MASKED() */

uint __thiscall std::__basic_file<char>::MASKED(__basic_file<char> *this)

{
  undefined4 uVar1;
  int iVar2;
  uint uVar3;
  uint uVar4;
  undefined8 uVar5;
  undefined1 auStack_c0 [24];
  uint local_a8;
  int local_88;
  uint local_84;
  undefined4 local_20;
  undefined2 local_1c;
  uint local_18 [3];
  
  local_18[0] = 0;
  uVar1 = fd(this);
  iVar2 = (*(code *)PTR_ioctl_004c5be8)(uVar1,0x467f,local_18);
  if ((iVar2 != 0) || ((int)local_18[0] < 0)) {
    local_20 = fd(this);
    local_1c = 1;
    iVar2 = (*(code *)PTR_poll_004c5b04)(&local_20,1,0);
    if (0 < iVar2) {
      uVar1 = fd(this);
      iVar2 = (*(code *)PTR___fxstat64_004c5adc)(3,uVar1,auStack_c0);
      if ((iVar2 == 0) && ((local_a8 & 0xf000) == 0x8000)) {
        uVar1 = fd(this);
        uVar5 = (*(code *)PTR_lseek64_004c5c6c)(uVar1);
        uVar4 = local_84 - (int)uVar5;
        uVar3 = local_88 - (int)((ulonglong)uVar5 >> 0x20);
        if (0 < (int)(uVar3 - (local_84 < uVar4))) {
          return 0x7fffffff;
        }
        if (uVar3 != local_84 < uVar4) {
          return uVar4;
        }
        if (uVar4 < 0x80000000) {
          return uVar4;
        }
        return 0x7fffffff;
      }
    }
    local_18[0] = 0;
  }
  return local_18[0];
}

