
/* std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) */

string * __thiscall
std::string::_M_replace_safe(string *this,uint param_1,uint param_2,char *param_3,uint param_4)

{
  _M_mutate(this,param_1,param_2,param_4);
  if (param_4 != 0) {
    if (param_4 == 1) {
      *(char *)(*(int *)this + param_1) = *param_3;
      return this;
    }
    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);
  }
  return this;
}



/* std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) */

string * __thiscall
std::string::_M_replace_safe(string *this,uint param_1,uint param_2,char *param_3,uint param_4)

{
  _M_mutate(this,param_1,param_2,param_4);
  if (param_4 != 0) {
    if (param_4 == 1) {
      *(char *)(*(int *)this + param_1) = *param_3;
      return this;
    }
    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);
  }
  return this;
}


lui gp,0x14
addiu gp,gp,-0x2774
addu gp,gp,t9
addiu sp,sp,-0x30
lw t9,-0x6940(gp)
sw s0,0x1c(sp)
sw gp,0x10(sp)
sw s3,0x28(sp)
or s3,a1,zero
sw s2,0x24(sp)
or s2,a3,zero
sw s1,0x20(sp)
or s1,a0,zero
sw ra,0x2c(sp)
lw s0,0x40(sp)
bal 0x002fbeb0
_or a3,s0,zero
beq s0,zero,0x002fc9b0
_lw gp,0x10(sp)
lw a0,0x0(s1)
li v0,0x1
beq s0,v0,0x002fc9d0
_addu a0,a0,s3
lw t9,-0x3a48(gp)
or a2,s0,zero
jalr t9
_or a1,s2,zero
lw ra,0x2c(sp)
or v0,s1,zero
lw s3,0x28(sp)
lw s2,0x24(sp)
lw s1,0x20(sp)
lw s0,0x1c(sp)
jr ra
_addiu sp,sp,0x30
lb v0,0x0(s2)
sb v0,0x0(a0)
or v0,s1,zero
lw ra,0x2c(sp)
lw s3,0x28(sp)
lw s2,0x24(sp)
lw s1,0x20(sp)
lw s0,0x1c(sp)
jr ra
_addiu sp,sp,0x30
(translation_unit "/* std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) */\n\nstring * __thiscall\nstd::string::_M_replace_safe(string *this,uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);\n  if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }\n  return this;\n}\n\n" comment (ERROR "string * __thiscall\nstd::string::_M_replace_safe(string *this," (binary_expression "string * __thiscall\nstd::string::_M_replace_safe(string *this" (binary_expression "string * __thiscall" identifier * identifier) (ERROR "std::string::_M_replace_safe(string" identifier : : identifier : : identifier ( identifier) * identifier) ,) (declaration "uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);" type_identifier identifier , (ERROR "uint" identifier) identifier , (ERROR "char" identifier) (pointer_declarator "*param_3" * identifier) , (ERROR "uint param_4)\n\n{" identifier identifier ) {) (function_declarator "_M_mutate(this,param_1,param_2,param_4)" identifier (parameter_list "(this,param_1,param_2,param_4)" ( (parameter_declaration "this" type_identifier) , (parameter_declaration "param_1" type_identifier) , (parameter_declaration "param_2" type_identifier) , (parameter_declaration "param_4" type_identifier) ))) ;) (if_statement "if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" if (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" { (if_statement "if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" { (expression_statement "*(char *)(*(int *)this + param_1) = *param_3;" (assignment_expression "*(char *)(*(int *)this + param_1) = *param_3" (pointer_expression "*(char *)(*(int *)this + param_1)" * (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) )))) = (pointer_expression "*param_3" * identifier)) ;) (return_statement "return this;" return identifier ;) })) (expression_statement "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);" (call_expression "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4)" (parenthesized_expression "(*(code *)PTR_memcpy_00436788)" ( (pointer_expression "*(code *)PTR_memcpy_00436788" * (cast_expression "(code *)PTR_memcpy_00436788" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "((char *)(*(int *)this + param_1),param_3,param_4)" ( (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) ))) , identifier , identifier ))) ;) })) (return_statement "return this;" return identifier ;) (ERROR "}" }))
(translation_unit "/* std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) */\n\nstring * __thiscall\nstd::string::_M_replace_safe(string *this,uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);\n  if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }\n  return this;\n}\n\n" comment (ERROR "string * __thiscall\nstd::string::_M_replace_safe(string *this," (binary_expression "string * __thiscall\nstd::string::_M_replace_safe(string *this" (binary_expression "string * __thiscall" identifier * identifier) (ERROR "std::string::_M_replace_safe(string" identifier : : identifier : : identifier ( identifier) * identifier) ,) (declaration "uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);" type_identifier identifier , (ERROR "uint" identifier) identifier , (ERROR "char" identifier) (pointer_declarator "*param_3" * identifier) , (ERROR "uint param_4)\n\n{" identifier identifier ) {) (function_declarator "_M_mutate(this,param_1,param_2,param_4)" identifier (parameter_list "(this,param_1,param_2,param_4)" ( (parameter_declaration "this" type_identifier) , (parameter_declaration "param_1" type_identifier) , (parameter_declaration "param_2" type_identifier) , (parameter_declaration "param_4" type_identifier) ))) ;) (if_statement "if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" if (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" { (if_statement "if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" { (expression_statement "*(char *)(*(int *)this + param_1) = *param_3;" (assignment_expression "*(char *)(*(int *)this + param_1) = *param_3" (pointer_expression "*(char *)(*(int *)this + param_1)" * (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) )))) = (pointer_expression "*param_3" * identifier)) ;) (return_statement "return this;" return identifier ;) })) (expression_statement "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);" (call_expression "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4)" (parenthesized_expression "(*(code *)PTR_memcpy_00436788)" ( (pointer_expression "*(code *)PTR_memcpy_00436788" * (cast_expression "(code *)PTR_memcpy_00436788" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "((char *)(*(int *)this + param_1),param_3,param_4)" ( (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) ))) , identifier , identifier ))) ;) })) (return_statement "return this;" return identifier ;) (ERROR "}" }))
(translation_unit "string * __thiscall\nstd::string::_M_replace_safe(string *this,uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);\n  if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }\n  return this;\n}\n\n" (ERROR "string * __thiscall\nstd::string::_M_replace_safe(string *this," (binary_expression "string * __thiscall\nstd::string::_M_replace_safe(string *this" (binary_expression "string * __thiscall" identifier * identifier) (ERROR "std::string::_M_replace_safe(string" identifier : : identifier : : identifier ( identifier) * identifier) ,) (declaration "uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);" type_identifier identifier , (ERROR "uint" identifier) identifier , (ERROR "char" identifier) (pointer_declarator "*param_3" * identifier) , (ERROR "uint param_4)\n\n{" identifier identifier ) {) (function_declarator "_M_mutate(this,param_1,param_2,param_4)" identifier (parameter_list "(this,param_1,param_2,param_4)" ( (parameter_declaration "this" type_identifier) , (parameter_declaration "param_1" type_identifier) , (parameter_declaration "param_2" type_identifier) , (parameter_declaration "param_4" type_identifier) ))) ;) (if_statement "if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" if (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" { (if_statement "if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" { (expression_statement "*(char *)(*(int *)this + param_1) = *param_3;" (assignment_expression "*(char *)(*(int *)this + param_1) = *param_3" (pointer_expression "*(char *)(*(int *)this + param_1)" * (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) )))) = (pointer_expression "*param_3" * identifier)) ;) (return_statement "return this;" return identifier ;) })) (expression_statement "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);" (call_expression "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4)" (parenthesized_expression "(*(code *)PTR_memcpy_00436788)" ( (pointer_expression "*(code *)PTR_memcpy_00436788" * (cast_expression "(code *)PTR_memcpy_00436788" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "((char *)(*(int *)this + param_1),param_3,param_4)" ( (cast_expression "(char *)(*(int *)this + param_1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + param_1)" ( (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) ))) , identifier , identifier ))) ;) })) (return_statement "return this;" return identifier ;) (ERROR "}" }))
(translation_unit (ERROR (binary_expression (binary_expression IDENT * IDENT) (ERROR IDENT : : IDENT : : IDENT ( IDENT) * IDENT) ,) (declaration TYPE IDENT , (ERROR IDENT) IDENT , (ERROR IDENT) (pointer_declarator * IDENT) , (ERROR IDENT IDENT ) {) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE) , (parameter_declaration TYPE) , (parameter_declaration TYPE) , (parameter_declaration TYPE) ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) + IDENT) )))) = (pointer_expression * IDENT)) ;) (return_statement return IDENT ;) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) + IDENT) ))) , IDENT , IDENT ))) ;) })) (return_statement return IDENT ;) (ERROR }))
(ERROR "string * __thiscall\nstd::string::_M_replace_safe(string *this," (binary_expression "string * __thiscall\nstd::string::_M_replace_safe(string *this" (binary_expression "string * __thiscall" (identifier "string") (* "*") (identifier "__thiscall")) (ERROR "std::string::_M_replace_safe(string" (identifier "std") (: ":") (: ":") (identifier "string") (: ":") (: ":") (identifier "_M_replace_safe") (( "(") (identifier "string")) (* "*") (identifier "this")) (, ",")) (declaration "uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  _M_mutate(this,param_1,param_2,param_4);" (type_identifier "uint") (identifier "param_1") (, ",") (ERROR "uint" (identifier "uint")) (identifier "param_2") (, ",") (ERROR "char" (identifier "char")) (pointer_declarator "*param_3" (* "*") (identifier "param_3")) (, ",") (ERROR "uint param_4)\n\n{" (identifier "uint") (identifier "param_4") () ")") ({ "{")) (function_declarator "_M_mutate(this,param_1,param_2,param_4)" (identifier "_M_mutate") (parameter_list "(this,param_1,param_2,param_4)" (( "(") (parameter_declaration "this" (type_identifier "this")) (, ",") (parameter_declaration "param_1" (type_identifier "param_1")) (, ",") (parameter_declaration "param_2" (type_identifier "param_2")) (, ",") (parameter_declaration "param_4" (type_identifier "param_4")) () ")"))) (; ";")) (if_statement "if (param_4 != 0) {\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" (if "if") (parenthesized_expression "(param_4 != 0)" (( "(") (binary_expression "param_4 != 0" (identifier "param_4") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }\n    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);\n  }" ({ "{") (if_statement "if (param_4 == 1) {\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" (if "if") (parenthesized_expression "(param_4 == 1)" (( "(") (binary_expression "param_4 == 1" (identifier "param_4") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      *(char *)(*(int *)this + param_1) = *param_3;\n      return this;\n    }" ({ "{") (expression_statement "*(char *)(*(int *)this + param_1) = *param_3;" (assignment_expression "*(char *)(*(int *)this + param_1) = *param_3" (pointer_expression "*(char *)(*(int *)this + param_1)" (* "*") (cast_expression "(char *)(*(int *)this + param_1)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*(int *)this + param_1)" (( "(") (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" (* "*") (cast_expression "(int *)this" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "this"))) (+ "+") (identifier "param_1")) () ")")))) (= "=") (pointer_expression "*param_3" (* "*") (identifier "param_3"))) (; ";")) (return_statement "return this;" (return "return") (identifier "this") (; ";")) (} "}"))) (expression_statement "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);" (call_expression "(*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4)" (parenthesized_expression "(*(code *)PTR_memcpy_00436788)" (( "(") (pointer_expression "*(code *)PTR_memcpy_00436788" (* "*") (cast_expression "(code *)PTR_memcpy_00436788" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_memcpy_00436788"))) () ")")) (argument_list "((char *)(*(int *)this + param_1),param_3,param_4)" (( "(") (cast_expression "(char *)(*(int *)this + param_1)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*(int *)this + param_1)" (( "(") (binary_expression "*(int *)this + param_1" (pointer_expression "*(int *)this" (* "*") (cast_expression "(int *)this" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "this"))) (+ "+") (identifier "param_1")) () ")"))) (, ",") (identifier "param_3") (, ",") (identifier "param_4") () ")"))) (; ";")) (} "}"))) (return_statement "return this;" (return "return") (identifier "this") (; ";")) (ERROR "}" (} "}"))

/* std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) */

string * __thiscall
std::string::_M_replace_safe(string *type_2,type_1 type_3,type_1 type_4,char *param_3,type_1 type_5)

{
  function_1(type_2,type_3,type_4,type_5);
  if (type_5 != 0) {
    if (type_5 == 1) {
      *(char *)(*(int *)type_2 + type_3) = *param_3;
      return type_2;
    }
    (*(type_6 *)PTR_memcpy_00436788)((char *)(*(int *)type_2 + type_3),param_3,type_5);
  }
  return type_2;
}


(translation_unit (ERROR (binary_expression left: (binary_expression left: (identifier) right: (identifier)) (ERROR (identifier) (identifier) (identifier) (identifier)) right: (identifier))) (declaration type: (type_identifier) declarator: (identifier) (ERROR (identifier)) declarator: (identifier) (ERROR (identifier)) declarator: (pointer_declarator declarator: (identifier)) (ERROR (identifier) (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier)) (parameter_declaration type: (type_identifier)) (parameter_declaration type: (type_identifier)) (parameter_declaration type: (type_identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (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: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier))) right: (identifier))))) right: (pointer_expression argument: (identifier)))) (return_statement (identifier)))) (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 (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier))) right: (identifier)))) (identifier) (identifier)))))) (return_statement (identifier)) (ERROR))

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

string * __thiscall
std::string::MASKED(string *this,uint param_1,uint param_2,char *param_3,uint param_4)

{
  _M_mutate(this,param_1,param_2,param_4);
  if (param_4 != 0) {
    if (param_4 == 1) {
      *(char *)(*(int *)this + param_1) = *param_3;
      return this;
    }
    (*(code *)PTR_memcpy_00436788)((char *)(*(int *)this + param_1),param_3,param_4);
  }
  return this;
}

