
/* std::string::_M_erase(unsigned int, unsigned int) */

void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  
  iVar4 = param_1 + param_2;
  iVar1 = *(int *)(this + 4);
  iVar3 = *(int *)this;
  if (iVar1 != iVar4) {
    iVar2 = iVar1 - param_2;
    if (param_2 == 0) goto LAB_0033ade0;
    if (iVar1 - iVar4 == 1) {
      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
    else {
      (*(code *)PTR_memmove_004c5af8)();
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
  }
  iVar2 = iVar1 - param_2;
LAB_0033ade0:
  *(int *)(this + 4) = iVar2;
  *(undefined1 *)(iVar3 + iVar2) = 0;
  return;
}



/* std::string::_M_erase(unsigned int, unsigned int) */

void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  
  iVar4 = param_1 + param_2;
  iVar1 = *(int *)(this + 4);
  iVar3 = *(int *)this;
  if (iVar1 != iVar4) {
    iVar2 = iVar1 - param_2;
    if (param_2 == 0) goto LAB_0033ade0;
    if (iVar1 - iVar4 == 1) {
      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
    else {
      (*(code *)PTR_memmove_004c5af8)();
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
  }
  iVar2 = iVar1 - param_2;
LAB_0033ade0:
  *(int *)(this + 4) = iVar2;
  *(undefined1 *)(iVar3 + iVar2) = 0;
  return;
}


lui gp,0x19
addiu gp,gp,-0x1b34
addu gp,gp,t9
addiu sp,sp,-0x28
addu a3,a1,a2
sw s1,0x20(sp)
or s1,a2,zero
sw s0,0x1c(sp)
or s0,a0,zero
sw gp,0x10(sp)
sw ra,0x24(sp)
lw v0,0x4(a0)
subu a2,v0,a3
beq a2,zero,0x0033addc
_lw v1,0x0(a0)
beq s1,zero,0x0033ade0
_subu v0,v0,s1
li v0,0x1
addu a0,v1,a1
beq a2,v0,0x0033ae00
_addu a1,v1,a3
lw t9,-0x3748(gp)
jalr t9
_nop
lw v0,0x4(s0)
lw v1,0x0(s0)
subu v0,v0,s1
addu v1,v1,v0
sw v0,0x4(s0)
sb zero,0x0(v1)
lw ra,0x24(sp)
lw s1,0x20(sp)
lw s0,0x1c(sp)
jr ra
_addiu sp,sp,0x28
lb v0,0x0(a1)
sb v0,0x0(a0)
lw v0,0x4(s0)
b 0x0033addc
_lw v1,0x0(s0)
(translation_unit "/* std::string::_M_erase(unsigned int, unsigned int) */\n\nvoid __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}\n\n" comment (function_definition "void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::string::" identifier : : identifier : :) (function_declarator "_M_erase(string *this,uint param_1,uint param_2)" identifier (parameter_list "(string *this,uint param_1,uint param_2)" ( (parameter_declaration "string *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "uint param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (expression_statement "iVar4 = param_1 + param_2;" (assignment_expression "iVar4 = param_1 + param_2" identifier = (binary_expression "param_1 + param_2" identifier + identifier)) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" if (parenthesized_expression "(iVar1 != iVar4)" ( (binary_expression "iVar1 != iVar4" identifier != identifier) )) (compound_statement "{\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" { (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (if_statement "if (param_2 == 0) goto LAB_0033ade0;" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (goto_statement "goto LAB_0033ade0;" goto statement_identifier ;)) (if_statement "if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" if (parenthesized_expression "(iVar1 - iVar4 == 1)" ( (binary_expression "iVar1 - iVar4 == 1" (binary_expression "iVar1 - iVar4" identifier - identifier) == number_literal) )) (compound_statement "{\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);" (assignment_expression "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4)" (pointer_expression "*(undefined1 *)(iVar3 + param_1)" * (cast_expression "(undefined1 *)(iVar3 + param_1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + param_1)" ( (binary_expression "iVar3 + param_1" identifier + identifier) )))) = (pointer_expression "*(undefined1 *)(iVar3 + iVar4)" * (cast_expression "(undefined1 *)(iVar3 + iVar4)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar4)" ( (binary_expression "iVar3 + iVar4" identifier + identifier) ))))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }) (else_clause "else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" else (compound_statement "{\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "(*(code *)PTR_memmove_004c5af8)();" (call_expression "(*(code *)PTR_memmove_004c5af8)()" (parenthesized_expression "(*(code *)PTR_memmove_004c5af8)" ( (pointer_expression "*(code *)PTR_memmove_004c5af8" * (cast_expression "(code *)PTR_memmove_004c5af8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }))) })) (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (labeled_statement "LAB_0033ade0:\n  *(int *)(this + 4) = iVar2;" statement_identifier : (expression_statement "*(int *)(this + 4) = iVar2;" (assignment_expression "*(int *)(this + 4) = iVar2" (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))) = identifier) ;)) (expression_statement "*(undefined1 *)(iVar3 + iVar2) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar2) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar2)" * (cast_expression "(undefined1 *)(iVar3 + iVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar2)" ( (binary_expression "iVar3 + iVar2" identifier + identifier) )))) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit "/* std::string::_M_erase(unsigned int, unsigned int) */\n\nvoid __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}\n\n" comment (function_definition "void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::string::" identifier : : identifier : :) (function_declarator "_M_erase(string *this,uint param_1,uint param_2)" identifier (parameter_list "(string *this,uint param_1,uint param_2)" ( (parameter_declaration "string *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "uint param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (expression_statement "iVar4 = param_1 + param_2;" (assignment_expression "iVar4 = param_1 + param_2" identifier = (binary_expression "param_1 + param_2" identifier + identifier)) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" if (parenthesized_expression "(iVar1 != iVar4)" ( (binary_expression "iVar1 != iVar4" identifier != identifier) )) (compound_statement "{\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" { (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (if_statement "if (param_2 == 0) goto LAB_0033ade0;" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (goto_statement "goto LAB_0033ade0;" goto statement_identifier ;)) (if_statement "if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" if (parenthesized_expression "(iVar1 - iVar4 == 1)" ( (binary_expression "iVar1 - iVar4 == 1" (binary_expression "iVar1 - iVar4" identifier - identifier) == number_literal) )) (compound_statement "{\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);" (assignment_expression "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4)" (pointer_expression "*(undefined1 *)(iVar3 + param_1)" * (cast_expression "(undefined1 *)(iVar3 + param_1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + param_1)" ( (binary_expression "iVar3 + param_1" identifier + identifier) )))) = (pointer_expression "*(undefined1 *)(iVar3 + iVar4)" * (cast_expression "(undefined1 *)(iVar3 + iVar4)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar4)" ( (binary_expression "iVar3 + iVar4" identifier + identifier) ))))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }) (else_clause "else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" else (compound_statement "{\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "(*(code *)PTR_memmove_004c5af8)();" (call_expression "(*(code *)PTR_memmove_004c5af8)()" (parenthesized_expression "(*(code *)PTR_memmove_004c5af8)" ( (pointer_expression "*(code *)PTR_memmove_004c5af8" * (cast_expression "(code *)PTR_memmove_004c5af8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }))) })) (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (labeled_statement "LAB_0033ade0:\n  *(int *)(this + 4) = iVar2;" statement_identifier : (expression_statement "*(int *)(this + 4) = iVar2;" (assignment_expression "*(int *)(this + 4) = iVar2" (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))) = identifier) ;)) (expression_statement "*(undefined1 *)(iVar3 + iVar2) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar2) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar2)" * (cast_expression "(undefined1 *)(iVar3 + iVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar2)" ( (binary_expression "iVar3 + iVar2" identifier + identifier) )))) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit "void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}\n\n" (function_definition "void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::string::" identifier : : identifier : :) (function_declarator "_M_erase(string *this,uint param_1,uint param_2)" identifier (parameter_list "(string *this,uint param_1,uint param_2)" ( (parameter_declaration "string *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "uint param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (expression_statement "iVar4 = param_1 + param_2;" (assignment_expression "iVar4 = param_1 + param_2" identifier = (binary_expression "param_1 + param_2" identifier + identifier)) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (if_statement "if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" if (parenthesized_expression "(iVar1 != iVar4)" ( (binary_expression "iVar1 != iVar4" identifier != identifier) )) (compound_statement "{\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" { (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (if_statement "if (param_2 == 0) goto LAB_0033ade0;" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (goto_statement "goto LAB_0033ade0;" goto statement_identifier ;)) (if_statement "if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" if (parenthesized_expression "(iVar1 - iVar4 == 1)" ( (binary_expression "iVar1 - iVar4 == 1" (binary_expression "iVar1 - iVar4" identifier - identifier) == number_literal) )) (compound_statement "{\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);" (assignment_expression "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4)" (pointer_expression "*(undefined1 *)(iVar3 + param_1)" * (cast_expression "(undefined1 *)(iVar3 + param_1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + param_1)" ( (binary_expression "iVar3 + param_1" identifier + identifier) )))) = (pointer_expression "*(undefined1 *)(iVar3 + iVar4)" * (cast_expression "(undefined1 *)(iVar3 + iVar4)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar4)" ( (binary_expression "iVar3 + iVar4" identifier + identifier) ))))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }) (else_clause "else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" else (compound_statement "{\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" { (expression_statement "(*(code *)PTR_memmove_004c5af8)();" (call_expression "(*(code *)PTR_memmove_004c5af8)()" (parenthesized_expression "(*(code *)PTR_memmove_004c5af8)" ( (pointer_expression "*(code *)PTR_memmove_004c5af8" * (cast_expression "(code *)PTR_memmove_004c5af8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" identifier = (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" identifier = (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }))) })) (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" identifier = (binary_expression "iVar1 - param_2" identifier - identifier)) ;) (labeled_statement "LAB_0033ade0:\n  *(int *)(this + 4) = iVar2;" statement_identifier : (expression_statement "*(int *)(this + 4) = iVar2;" (assignment_expression "*(int *)(this + 4) = iVar2" (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))) = identifier) ;)) (expression_statement "*(undefined1 *)(iVar3 + iVar2) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar2) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar2)" * (cast_expression "(undefined1 *)(iVar3 + iVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar2)" ( (binary_expression "iVar3 + iVar2" identifier + identifier) )))) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (ms_call_modifier __thiscall) (ERROR IDENT : : IDENT : :) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT - IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT - IDENT) == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT))) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT))) ;) }))) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT - IDENT)) ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;)) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) = LIT) ;) (return_statement return ;) })))
(function_definition "void __thiscall std::string::_M_erase(string *this,uint param_1,uint param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" (primitive_type "void") (ms_call_modifier "__thiscall" (__thiscall "__thiscall")) (ERROR "std::string::" (identifier "std") (: ":") (: ":") (identifier "string") (: ":") (: ":")) (function_declarator "_M_erase(string *this,uint param_1,uint param_2)" (identifier "_M_erase") (parameter_list "(string *this,uint param_1,uint param_2)" (( "(") (parameter_declaration "string *this" (type_identifier "string") (pointer_declarator "*this" (* "*") (identifier "this"))) (, ",") (parameter_declaration "uint param_1" (type_identifier "uint") (identifier "param_1")) (, ",") (parameter_declaration "uint param_2" (type_identifier "uint") (identifier "param_2")) () ")"))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  \n  iVar4 = param_1 + param_2;\n  iVar1 = *(int *)(this + 4);\n  iVar3 = *(int *)this;\n  if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }\n  iVar2 = iVar1 - param_2;\nLAB_0033ade0:\n  *(int *)(this + 4) = iVar2;\n  *(undefined1 *)(iVar3 + iVar2) = 0;\n  return;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (expression_statement "iVar4 = param_1 + param_2;" (assignment_expression "iVar4 = param_1 + param_2" (identifier "iVar4") (= "=") (binary_expression "param_1 + param_2" (identifier "param_1") (+ "+") (identifier "param_2"))) (; ";")) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(this + 4)" (* "*") (cast_expression "(int *)(this + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(this + 4)" (( "(") (binary_expression "this + 4" (identifier "this") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" (identifier "iVar3") (= "=") (pointer_expression "*(int *)this" (* "*") (cast_expression "(int *)this" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "this")))) (; ";")) (if_statement "if (iVar1 != iVar4) {\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" (if "if") (parenthesized_expression "(iVar1 != iVar4)" (( "(") (binary_expression "iVar1 != iVar4" (identifier "iVar1") (!= "!=") (identifier "iVar4")) () ")")) (compound_statement "{\n    iVar2 = iVar1 - param_2;\n    if (param_2 == 0) goto LAB_0033ade0;\n    if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n  }" ({ "{") (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" (identifier "iVar2") (= "=") (binary_expression "iVar1 - param_2" (identifier "iVar1") (- "-") (identifier "param_2"))) (; ";")) (if_statement "if (param_2 == 0) goto LAB_0033ade0;" (if "if") (parenthesized_expression "(param_2 == 0)" (( "(") (binary_expression "param_2 == 0" (identifier "param_2") (== "==") (number_literal "0")) () ")")) (goto_statement "goto LAB_0033ade0;" (goto "goto") (statement_identifier "LAB_0033ade0") (; ";"))) (if_statement "if (iVar1 - iVar4 == 1) {\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }\n    else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" (if "if") (parenthesized_expression "(iVar1 - iVar4 == 1)" (( "(") (binary_expression "iVar1 - iVar4 == 1" (binary_expression "iVar1 - iVar4" (identifier "iVar1") (- "-") (identifier "iVar4")) (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" ({ "{") (expression_statement "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);" (assignment_expression "*(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4)" (pointer_expression "*(undefined1 *)(iVar3 + param_1)" (* "*") (cast_expression "(undefined1 *)(iVar3 + param_1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + param_1)" (( "(") (binary_expression "iVar3 + param_1" (identifier "iVar3") (+ "+") (identifier "param_1")) () ")")))) (= "=") (pointer_expression "*(undefined1 *)(iVar3 + iVar4)" (* "*") (cast_expression "(undefined1 *)(iVar3 + iVar4)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + iVar4)" (( "(") (binary_expression "iVar3 + iVar4" (identifier "iVar3") (+ "+") (identifier "iVar4")) () ")"))))) (; ";")) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(this + 4)" (* "*") (cast_expression "(int *)(this + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(this + 4)" (( "(") (binary_expression "this + 4" (identifier "this") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" (identifier "iVar3") (= "=") (pointer_expression "*(int *)this" (* "*") (cast_expression "(int *)this" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "this")))) (; ";")) (} "}")) (else_clause "else {\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" (else "else") (compound_statement "{\n      (*(code *)PTR_memmove_004c5af8)();\n      iVar1 = *(int *)(this + 4);\n      iVar3 = *(int *)this;\n    }" ({ "{") (expression_statement "(*(code *)PTR_memmove_004c5af8)();" (call_expression "(*(code *)PTR_memmove_004c5af8)()" (parenthesized_expression "(*(code *)PTR_memmove_004c5af8)" (( "(") (pointer_expression "*(code *)PTR_memmove_004c5af8" (* "*") (cast_expression "(code *)PTR_memmove_004c5af8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_memmove_004c5af8"))) () ")")) (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "iVar1 = *(int *)(this + 4);" (assignment_expression "iVar1 = *(int *)(this + 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(this + 4)" (* "*") (cast_expression "(int *)(this + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(this + 4)" (( "(") (binary_expression "this + 4" (identifier "this") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (expression_statement "iVar3 = *(int *)this;" (assignment_expression "iVar3 = *(int *)this" (identifier "iVar3") (= "=") (pointer_expression "*(int *)this" (* "*") (cast_expression "(int *)this" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "this")))) (; ";")) (} "}")))) (} "}"))) (expression_statement "iVar2 = iVar1 - param_2;" (assignment_expression "iVar2 = iVar1 - param_2" (identifier "iVar2") (= "=") (binary_expression "iVar1 - param_2" (identifier "iVar1") (- "-") (identifier "param_2"))) (; ";")) (labeled_statement "LAB_0033ade0:\n  *(int *)(this + 4) = iVar2;" (statement_identifier "LAB_0033ade0") (: ":") (expression_statement "*(int *)(this + 4) = iVar2;" (assignment_expression "*(int *)(this + 4) = iVar2" (pointer_expression "*(int *)(this + 4)" (* "*") (cast_expression "(int *)(this + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(this + 4)" (( "(") (binary_expression "this + 4" (identifier "this") (+ "+") (number_literal "4")) () ")")))) (= "=") (identifier "iVar2")) (; ";"))) (expression_statement "*(undefined1 *)(iVar3 + iVar2) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar2) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar2)" (* "*") (cast_expression "(undefined1 *)(iVar3 + iVar2)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + iVar2)" (( "(") (binary_expression "iVar3 + iVar2" (identifier "iVar3") (+ "+") (identifier "iVar2")) () ")")))) (= "=") (number_literal "0")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* std::string::_M_erase(unsigned int, unsigned int) */

void __thiscall std::type_1::function_1(type_1 *var_3,type_2 var_1,type_2 var_2)

{
  int var_4;
  int var_7;
  int var_6;
  int var_5;
  
  var_5 = var_1 + var_2;
  var_4 = *(int *)(var_3 + 4);
  var_6 = *(int *)var_3;
  if (var_4 != var_5) {
    var_7 = var_4 - var_2;
    if (var_2 == 0) goto LAB_0033ade0;
    if (var_4 - var_5 == 1) {
      *(type_3 *)(var_6 + var_1) = *(type_3 *)(var_6 + var_5);
      var_4 = *(int *)(var_3 + 4);
      var_6 = *(int *)var_3;
    }
    else {
      (*(type_4 *)PTR_memmove_004c5af8)();
      var_4 = *(int *)(var_3 + 4);
      var_6 = *(int *)var_3;
    }
  }
  var_7 = var_4 - var_2;
LAB_0033ade0:
  *(int *)(var_3 + 4) = var_7;
  *(type_3 *)(var_6 + var_7) = 0;
  return;
}


(translation_unit (function_definition type: (primitive_type) (ms_call_modifier) (ERROR (identifier) (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier)))))) alternative: (else_clause (compound_statement (expression_statement (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))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier)))))))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))) (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))) right: (number_literal))) (return_statement))))

/* std::string::MASKED(unsigned int, unsigned int) */

void __thiscall std::string::MASKED(string *this,uint param_1,uint param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  
  iVar4 = param_1 + param_2;
  iVar1 = *(int *)(this + 4);
  iVar3 = *(int *)this;
  if (iVar1 != iVar4) {
    iVar2 = iVar1 - param_2;
    if (param_2 == 0) goto LAB_0033ade0;
    if (iVar1 - iVar4 == 1) {
      *(undefined1 *)(iVar3 + param_1) = *(undefined1 *)(iVar3 + iVar4);
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
    else {
      (*(code *)PTR_memmove_004c5af8)();
      iVar1 = *(int *)(this + 4);
      iVar3 = *(int *)this;
    }
  }
  iVar2 = iVar1 - param_2;
LAB_0033ade0:
  *(int *)(this + 4) = iVar2;
  *(undefined1 *)(iVar3 + iVar2) = 0;
  return;
}

