
/* std::string::_Rep::_M_clone(std::allocator<char> const&, unsigned long) */

size_t * __thiscall std::string::_Rep::_M_clone(_Rep *this,allocator *param_1,ulong param_2)

{
  size_t __n;
  size_t *psVar1;
  size_t *psVar2;
  size_t *__dest;
  
  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);
  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;
  __n = *(size_t *)this;
  __dest = psVar2 + 3;
  if (__n != 0) {
    if (__n == 1) {
      *(_Rep *)(psVar2 + 3) = this[0x18];
      __n = *(size_t *)this;
    }
    else {
      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);
      __n = *(size_t *)this;
      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;
    }
  }
  if (psVar2 != psVar1) {
    *(undefined4 *)(psVar2 + 2) = 0;
    *psVar2 = __n;
    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;
  }
  return __dest;
}



size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)

{
  size_t __n;
  size_t *psVar1;
  size_t *psVar2;
  size_t *__dest;
  
  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);
  psVar1 = (size_t *)PTR_DAT_00457c38;
  __n = *param_1;
  __dest = psVar2 + 3;
  if (__n != 0) {
    if (__n == 1) {
      *(char *)(psVar2 + 3) = (char)param_1[3];
      __n = *param_1;
    }
    else {
      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);
      __n = *param_1;
      psVar1 = (size_t *)PTR_DAT_00457c38;
    }
  }
  if (psVar2 != psVar1) {
    *(undefined4 *)(psVar2 + 2) = 0;
    *psVar2 = __n;
    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;
  }
  return __dest;
}


PUSH RBP
PUSH RBX
MOV RBX,RDI
SUB RSP,0x8
MOV RDI,qword ptr [RDI]
ADD RDI,RDX
MOV RDX,RSI
MOV RSI,qword ptr [RBX + 0x8]
CALL 0x00322b40
MOV RDX,qword ptr [RBX]
MOV RBP,RAX
LEA RCX,[RAX + 0x18]
TEST RDX,RDX
JZ 0x00323a32
CMP RDX,0x1
JZ 0x00323a48
MOV RDI,RCX
LEA RSI,[RBX + 0x18]
CALL 0x00149a90
MOV RDX,qword ptr [RBX]
MOV RCX,RAX
CMP RBP,qword ptr [0x00457c38]
JNZ 0x00323a60
ADD RSP,0x8
MOV RAX,RCX
POP RBX
POP RBP
RET
MOVZX EAX,byte ptr [RBX + 0x18]
CMP RBP,qword ptr [0x00457c38]
MOV byte ptr [RBP + 0x18],AL
MOV RDX,qword ptr [RBX]
JZ 0x00323a3b
NOP dword ptr [RAX + RAX*0x1]
MOV dword ptr [RBP + 0x10],0x0
MOV qword ptr [RBP],RDX
MOV byte ptr [RBP + RDX*0x1 + 0x18],0x0
JMP 0x00323a3b
(translation_unit "size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}\n\n" (function_definition "size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" primitive_type (pointer_declarator "* FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" * (function_declarator "FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" identifier (parameter_list "(size_t *param_1,undefined8 param_2,long param_3)" ( (parameter_declaration "size_t *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined8 param_2" type_identifier identifier) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) )))) (compound_statement "{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "size_t *psVar1;" primitive_type (pointer_declarator "*psVar1" * identifier) ;) (declaration "size_t *psVar2;" primitive_type (pointer_declarator "*psVar2" * identifier) ;) (declaration "size_t *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (expression_statement "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);" (assignment_expression "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" identifier = (cast_expression "(size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" identifier (argument_list "(*param_1 + param_3,param_1[1],param_2)" ( (binary_expression "*param_1 + param_3" (pointer_expression "*param_1" * identifier) + identifier) , (subscript_expression "param_1[1]" identifier [ number_literal ]) , identifier ))))) ;) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" identifier = (cast_expression "(size_t *)PTR_DAT_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "__dest = psVar2 + 3;" (assignment_expression "__dest = psVar2 + 3" identifier = (binary_expression "psVar2 + 3" identifier + number_literal)) ;) (if_statement "if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" { (if_statement "if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }" { (expression_statement "*(char *)(psVar2 + 3) = (char)param_1[3];" (assignment_expression "*(char *)(psVar2 + 3) = (char)param_1[3]" (pointer_expression "*(char *)(psVar2 + 3)" * (cast_expression "(char *)(psVar2 + 3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 3)" ( (binary_expression "psVar2 + 3" identifier + number_literal) )))) = (cast_expression "(char)param_1[3]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "param_1[3]" identifier [ number_literal ]))) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) }) (else_clause "else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" else (compound_statement "{\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" { (expression_statement "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n);" (assignment_expression "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n)" identifier = (cast_expression "(size_t *)memcpy(__dest,param_1 + 3,__n)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memcpy(__dest,param_1 + 3,__n)" identifier (argument_list "(__dest,param_1 + 3,__n)" ( identifier , (binary_expression "param_1 + 3" identifier + number_literal) , identifier ))))) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" identifier = (cast_expression "(size_t *)PTR_DAT_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) }))) })) (if_statement "if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" if (parenthesized_expression "(psVar2 != psVar1)" ( (binary_expression "psVar2 != psVar1" identifier != identifier) )) (compound_statement "{\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" { (expression_statement "*(undefined4 *)(psVar2 + 2) = 0;" (assignment_expression "*(undefined4 *)(psVar2 + 2) = 0" (pointer_expression "*(undefined4 *)(psVar2 + 2)" * (cast_expression "(undefined4 *)(psVar2 + 2)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 2)" ( (binary_expression "psVar2 + 2" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*psVar2 = __n;" (assignment_expression "*psVar2 = __n" (pointer_expression "*psVar2" * identifier) = identifier) ;) (expression_statement "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0;" (assignment_expression "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0" (pointer_expression "*(undefined1 *)((long)psVar2 + __n + 0x18)" * (cast_expression "(undefined1 *)((long)psVar2 + __n + 0x18)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((long)psVar2 + __n + 0x18)" ( (binary_expression "(long)psVar2 + __n + 0x18" (binary_expression "(long)psVar2 + __n" (cast_expression "(long)psVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) + identifier) + number_literal) )))) = number_literal) ;) })) (return_statement "return __dest;" return identifier ;) })))
(translation_unit "/* std::string::_Rep::_M_clone(std::allocator<char> const&, unsigned long) */\n\nsize_t * __thiscall std::string::_Rep::_M_clone(_Rep *this,allocator *param_1,ulong param_2)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);\n  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n  __n = *(size_t *)this;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}\n\n" comment (declaration "size_t * __thiscall" primitive_type (pointer_declarator "* __thiscall" * identifier) ;) (labeled_statement "std::string::_Rep::_M_clone(_Rep *this,allocator *param_1,ulong param_2)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);\n  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n  __n = *(size_t *)this;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" statement_identifier : (ERROR ":" :) (labeled_statement "string::_Rep::_M_clone(_Rep *this,allocator *param_1,ulong param_2)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);\n  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n  __n = *(size_t *)this;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" statement_identifier : (ERROR ":" :) (labeled_statement "_Rep::_M_clone(_Rep *this,allocator *param_1,ulong param_2)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);\n  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n  __n = *(size_t *)this;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" statement_identifier : (ERROR ":_M_clone(_Rep *this,allocator *param_1,ulong param_2)" : (call_expression "_M_clone(_Rep *this,allocator *param_1,ulong param_2)" identifier (argument_list "(_Rep *this,allocator *param_1,ulong param_2)" ( (binary_expression "_Rep *this" identifier * identifier) , (binary_expression "allocator *param_1" identifier * identifier) , (ERROR "ulong" identifier) identifier )))) (compound_statement "{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);\n  psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n  __n = *(size_t *)this;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "size_t *psVar1;" primitive_type (pointer_declarator "*psVar1" * identifier) ;) (declaration "size_t *psVar2;" primitive_type (pointer_declarator "*psVar2" * identifier) ;) (declaration "size_t *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (expression_statement "psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1);" (assignment_expression "psVar2 = (size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1)" identifier = (cast_expression "(size_t *)_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "_S_create(*(long *)this + param_2,*(ulong *)(this + 8),param_1)" identifier (argument_list "(*(long *)this + param_2,*(ulong *)(this + 8),param_1)" ( (binary_expression "*(long *)this + param_2" (pointer_expression "*(long *)this" * (cast_expression "(long *)this" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) identifier)) + identifier) , (pointer_expression "*(ulong *)(this + 8)" * (cast_expression "(ulong *)(this + 8)" ( (type_descriptor "ulong *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) )))) , identifier ))))) ;) (expression_statement "psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38" identifier = (cast_expression "(size_t *)PTR__S_empty_rep_storage_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "__n = *(size_t *)this;" (assignment_expression "__n = *(size_t *)this" identifier = (pointer_expression "*(size_t *)this" * (cast_expression "(size_t *)this" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (expression_statement "__dest = psVar2 + 3;" (assignment_expression "__dest = psVar2 + 3" identifier = (binary_expression "psVar2 + 3" identifier + number_literal)) ;) (if_statement "if (__n != 0) {\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }\n  }" { (if_statement "if (__n == 1) {\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      *(_Rep *)(psVar2 + 3) = this[0x18];\n      __n = *(size_t *)this;\n    }" { (expression_statement "*(_Rep *)(psVar2 + 3) = this[0x18];" (assignment_expression "*(_Rep *)(psVar2 + 3) = this[0x18]" (pointer_expression "*(_Rep *)(psVar2 + 3)" * (cast_expression "(_Rep *)(psVar2 + 3)" ( (type_descriptor "_Rep *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 3)" ( (binary_expression "psVar2 + 3" identifier + number_literal) )))) = (subscript_expression "this[0x18]" identifier [ number_literal ])) ;) (expression_statement "__n = *(size_t *)this;" (assignment_expression "__n = *(size_t *)this" identifier = (pointer_expression "*(size_t *)this" * (cast_expression "(size_t *)this" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) }) (else_clause "else {\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }" else (compound_statement "{\n      __dest = (size_t *)memcpy(__dest,this + 0x18,__n);\n      __n = *(size_t *)this;\n      psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;\n    }" { (expression_statement "__dest = (size_t *)memcpy(__dest,this + 0x18,__n);" (assignment_expression "__dest = (size_t *)memcpy(__dest,this + 0x18,__n)" identifier = (cast_expression "(size_t *)memcpy(__dest,this + 0x18,__n)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memcpy(__dest,this + 0x18,__n)" identifier (argument_list "(__dest,this + 0x18,__n)" ( identifier , (binary_expression "this + 0x18" identifier + number_literal) , identifier ))))) ;) (expression_statement "__n = *(size_t *)this;" (assignment_expression "__n = *(size_t *)this" identifier = (pointer_expression "*(size_t *)this" * (cast_expression "(size_t *)this" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier))) ;) (expression_statement "psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR__S_empty_rep_storage_00457c38" identifier = (cast_expression "(size_t *)PTR__S_empty_rep_storage_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) }))) })) (if_statement "if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" if (parenthesized_expression "(psVar2 != psVar1)" ( (binary_expression "psVar2 != psVar1" identifier != identifier) )) (compound_statement "{\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" { (expression_statement "*(undefined4 *)(psVar2 + 2) = 0;" (assignment_expression "*(undefined4 *)(psVar2 + 2) = 0" (pointer_expression "*(undefined4 *)(psVar2 + 2)" * (cast_expression "(undefined4 *)(psVar2 + 2)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 2)" ( (binary_expression "psVar2 + 2" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*psVar2 = __n;" (assignment_expression "*psVar2 = __n" (pointer_expression "*psVar2" * identifier) = identifier) ;) (expression_statement "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0;" (assignment_expression "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0" (pointer_expression "*(undefined1 *)((long)psVar2 + __n + 0x18)" * (cast_expression "(undefined1 *)((long)psVar2 + __n + 0x18)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((long)psVar2 + __n + 0x18)" ( (binary_expression "(long)psVar2 + __n + 0x18" (binary_expression "(long)psVar2 + __n" (cast_expression "(long)psVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) + identifier) + number_literal) )))) = number_literal) ;) })) (return_statement "return __dest;" return identifier ;) })))))
(translation_unit "size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}\n\n" (function_definition "size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" primitive_type (pointer_declarator "* FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" * (function_declarator "FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" identifier (parameter_list "(size_t *param_1,undefined8 param_2,long param_3)" ( (parameter_declaration "size_t *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined8 param_2" type_identifier identifier) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) )))) (compound_statement "{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "size_t *psVar1;" primitive_type (pointer_declarator "*psVar1" * identifier) ;) (declaration "size_t *psVar2;" primitive_type (pointer_declarator "*psVar2" * identifier) ;) (declaration "size_t *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (expression_statement "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);" (assignment_expression "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" identifier = (cast_expression "(size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" identifier (argument_list "(*param_1 + param_3,param_1[1],param_2)" ( (binary_expression "*param_1 + param_3" (pointer_expression "*param_1" * identifier) + identifier) , (subscript_expression "param_1[1]" identifier [ number_literal ]) , identifier ))))) ;) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" identifier = (cast_expression "(size_t *)PTR_DAT_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "__dest = psVar2 + 3;" (assignment_expression "__dest = psVar2 + 3" identifier = (binary_expression "psVar2 + 3" identifier + number_literal)) ;) (if_statement "if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" { (if_statement "if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }" { (expression_statement "*(char *)(psVar2 + 3) = (char)param_1[3];" (assignment_expression "*(char *)(psVar2 + 3) = (char)param_1[3]" (pointer_expression "*(char *)(psVar2 + 3)" * (cast_expression "(char *)(psVar2 + 3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 3)" ( (binary_expression "psVar2 + 3" identifier + number_literal) )))) = (cast_expression "(char)param_1[3]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "param_1[3]" identifier [ number_literal ]))) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) }) (else_clause "else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" else (compound_statement "{\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" { (expression_statement "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n);" (assignment_expression "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n)" identifier = (cast_expression "(size_t *)memcpy(__dest,param_1 + 3,__n)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memcpy(__dest,param_1 + 3,__n)" identifier (argument_list "(__dest,param_1 + 3,__n)" ( identifier , (binary_expression "param_1 + 3" identifier + number_literal) , identifier ))))) ;) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" identifier = (cast_expression "(size_t *)PTR_DAT_00457c38" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) }))) })) (if_statement "if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" if (parenthesized_expression "(psVar2 != psVar1)" ( (binary_expression "psVar2 != psVar1" identifier != identifier) )) (compound_statement "{\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" { (expression_statement "*(undefined4 *)(psVar2 + 2) = 0;" (assignment_expression "*(undefined4 *)(psVar2 + 2) = 0" (pointer_expression "*(undefined4 *)(psVar2 + 2)" * (cast_expression "(undefined4 *)(psVar2 + 2)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(psVar2 + 2)" ( (binary_expression "psVar2 + 2" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*psVar2 = __n;" (assignment_expression "*psVar2 = __n" (pointer_expression "*psVar2" * identifier) = identifier) ;) (expression_statement "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0;" (assignment_expression "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0" (pointer_expression "*(undefined1 *)((long)psVar2 + __n + 0x18)" * (cast_expression "(undefined1 *)((long)psVar2 + __n + 0x18)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((long)psVar2 + __n + 0x18)" ( (binary_expression "(long)psVar2 + __n + 0x18" (binary_expression "(long)psVar2 + __n" (cast_expression "(long)psVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) + identifier) + number_literal) )))) = number_literal) ;) })) (return_statement "return __dest;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration (sized_type_specifier long) IDENT) )))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( (binary_expression (pointer_expression * IDENT) + IDENT) , (subscript_expression IDENT [ LIT ]) , IDENT ))))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (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 IDENT + LIT) )))) = (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ]))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , (binary_expression IDENT + LIT) , IDENT ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) }))) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != IDENT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT) + IDENT) + LIT) )))) = LIT) ;) })) (return_statement return IDENT ;) })))
(function_definition "size_t * FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)\n\n{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" (primitive_type "size_t") (pointer_declarator "* FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" (* "*") (function_declarator "FUN_003239f0(size_t *param_1,undefined8 param_2,long param_3)" (identifier "FUN_003239f0") (parameter_list "(size_t *param_1,undefined8 param_2,long param_3)" (( "(") (parameter_declaration "size_t *param_1" (primitive_type "size_t") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "undefined8 param_2" (type_identifier "undefined8") (identifier "param_2")) (, ",") (parameter_declaration "long param_3" (sized_type_specifier "long" (long "long")) (identifier "param_3")) () ")")))) (compound_statement "{\n  size_t __n;\n  size_t *psVar1;\n  size_t *psVar2;\n  size_t *__dest;\n  \n  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);\n  psVar1 = (size_t *)PTR_DAT_00457c38;\n  __n = *param_1;\n  __dest = psVar2 + 3;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }\n  if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }\n  return __dest;\n}" ({ "{") (declaration "size_t __n;" (primitive_type "size_t") (identifier "__n") (; ";")) (declaration "size_t *psVar1;" (primitive_type "size_t") (pointer_declarator "*psVar1" (* "*") (identifier "psVar1")) (; ";")) (declaration "size_t *psVar2;" (primitive_type "size_t") (pointer_declarator "*psVar2" (* "*") (identifier "psVar2")) (; ";")) (declaration "size_t *__dest;" (primitive_type "size_t") (pointer_declarator "*__dest" (* "*") (identifier "__dest")) (; ";")) (expression_statement "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);" (assignment_expression "psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" (identifier "psVar2") (= "=") (cast_expression "(size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_00322b40(*param_1 + param_3,param_1[1],param_2)" (identifier "FUN_00322b40") (argument_list "(*param_1 + param_3,param_1[1],param_2)" (( "(") (binary_expression "*param_1 + param_3" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (+ "+") (identifier "param_3")) (, ",") (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (, ",") (identifier "param_2") () ")"))))) (; ";")) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" (identifier "psVar1") (= "=") (cast_expression "(size_t *)PTR_DAT_00457c38" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_DAT_00457c38"))) (; ";")) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" (identifier "__n") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (expression_statement "__dest = psVar2 + 3;" (assignment_expression "__dest = psVar2 + 3" (identifier "__dest") (= "=") (binary_expression "psVar2 + 3" (identifier "psVar2") (+ "+") (number_literal "3"))) (; ";")) (if_statement "if (__n != 0) {\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" (if "if") (parenthesized_expression "(__n != 0)" (( "(") (binary_expression "__n != 0" (identifier "__n") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }\n  }" ({ "{") (if_statement "if (__n == 1) {\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }\n    else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" (if "if") (parenthesized_expression "(__n == 1)" (( "(") (binary_expression "__n == 1" (identifier "__n") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      *(char *)(psVar2 + 3) = (char)param_1[3];\n      __n = *param_1;\n    }" ({ "{") (expression_statement "*(char *)(psVar2 + 3) = (char)param_1[3];" (assignment_expression "*(char *)(psVar2 + 3) = (char)param_1[3]" (pointer_expression "*(char *)(psVar2 + 3)" (* "*") (cast_expression "(char *)(psVar2 + 3)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(psVar2 + 3)" (( "(") (binary_expression "psVar2 + 3" (identifier "psVar2") (+ "+") (number_literal "3")) () ")")))) (= "=") (cast_expression "(char)param_1[3]" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (subscript_expression "param_1[3]" (identifier "param_1") ([ "[") (number_literal "3") (] "]")))) (; ";")) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" (identifier "__n") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (} "}")) (else_clause "else {\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" (else "else") (compound_statement "{\n      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);\n      __n = *param_1;\n      psVar1 = (size_t *)PTR_DAT_00457c38;\n    }" ({ "{") (expression_statement "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n);" (assignment_expression "__dest = (size_t *)memcpy(__dest,param_1 + 3,__n)" (identifier "__dest") (= "=") (cast_expression "(size_t *)memcpy(__dest,param_1 + 3,__n)" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "memcpy(__dest,param_1 + 3,__n)" (identifier "memcpy") (argument_list "(__dest,param_1 + 3,__n)" (( "(") (identifier "__dest") (, ",") (binary_expression "param_1 + 3" (identifier "param_1") (+ "+") (number_literal "3")) (, ",") (identifier "__n") () ")"))))) (; ";")) (expression_statement "__n = *param_1;" (assignment_expression "__n = *param_1" (identifier "__n") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (expression_statement "psVar1 = (size_t *)PTR_DAT_00457c38;" (assignment_expression "psVar1 = (size_t *)PTR_DAT_00457c38" (identifier "psVar1") (= "=") (cast_expression "(size_t *)PTR_DAT_00457c38" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_DAT_00457c38"))) (; ";")) (} "}")))) (} "}"))) (if_statement "if (psVar2 != psVar1) {\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" (if "if") (parenthesized_expression "(psVar2 != psVar1)" (( "(") (binary_expression "psVar2 != psVar1" (identifier "psVar2") (!= "!=") (identifier "psVar1")) () ")")) (compound_statement "{\n    *(undefined4 *)(psVar2 + 2) = 0;\n    *psVar2 = __n;\n    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;\n  }" ({ "{") (expression_statement "*(undefined4 *)(psVar2 + 2) = 0;" (assignment_expression "*(undefined4 *)(psVar2 + 2) = 0" (pointer_expression "*(undefined4 *)(psVar2 + 2)" (* "*") (cast_expression "(undefined4 *)(psVar2 + 2)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(psVar2 + 2)" (( "(") (binary_expression "psVar2 + 2" (identifier "psVar2") (+ "+") (number_literal "2")) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "*psVar2 = __n;" (assignment_expression "*psVar2 = __n" (pointer_expression "*psVar2" (* "*") (identifier "psVar2")) (= "=") (identifier "__n")) (; ";")) (expression_statement "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0;" (assignment_expression "*(undefined1 *)((long)psVar2 + __n + 0x18) = 0" (pointer_expression "*(undefined1 *)((long)psVar2 + __n + 0x18)" (* "*") (cast_expression "(undefined1 *)((long)psVar2 + __n + 0x18)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((long)psVar2 + __n + 0x18)" (( "(") (binary_expression "(long)psVar2 + __n + 0x18" (binary_expression "(long)psVar2 + __n" (cast_expression "(long)psVar2" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "psVar2")) (+ "+") (identifier "__n")) (+ "+") (number_literal "0x18")) () ")")))) (= "=") (number_literal "0")) (; ";")) (} "}"))) (return_statement "return __dest;" (return "return") (identifier "__dest") (; ";")) (} "}")))

/* std::string::_Rep::_M_clone(std::allocator<char> const&, unsigned long) */

size_t * __thiscall std::string::_Rep::_M_clone(type_2 *var_3,allocator *param_1,type_1 var_2)

{
  size_t var_5;
  size_t *var_7;
  size_t *var_4;
  size_t *__dest;
  
  var_4 = (size_t *)var_1(*(long *)var_3 + var_2,*(type_1 *)(var_3 + 8),param_1);
  var_7 = (size_t *)PTR__S_empty_rep_storage_00457c38;
  var_5 = *(size_t *)var_3;
  __dest = var_4 + 3;
  if (var_5 != 0) {
    if (var_5 == 1) {
      *(type_2 *)(var_4 + 3) = var_3[0x18];
      var_5 = *(size_t *)var_3;
    }
    else {
      __dest = (size_t *)var_6(__dest,var_3 + 0x18,var_5);
      var_5 = *(size_t *)var_3;
      var_7 = (size_t *)PTR__S_empty_rep_storage_00457c38;
    }
  }
  if (var_4 != var_7) {
    *(type_3 *)(var_4 + 2) = 0;
    *var_4 = var_5;
    *(type_4 *)((long)var_4 + var_5 + 0x18) = 0;
  }
  return __dest;
}


(translation_unit (function_definition type: (primitive_type) declarator: (pointer_declarator declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (sized_type_specifier) declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier)) (subscript_expression argument: (identifier) index: (number_literal)) (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (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: (identifier) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier) (binary_expression left: (identifier) right: (number_literal)) (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (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: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) 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: (binary_expression left: (cast_expression type: (type_descriptor type: (sized_type_specifier)) value: (identifier)) right: (identifier)) right: (number_literal))))) right: (number_literal))))) (return_statement (identifier)))))

size_t * MASKED(size_t *param_1,undefined8 param_2,long param_3)

{
  size_t __n;
  size_t *psVar1;
  size_t *psVar2;
  size_t *__dest;
  
  psVar2 = (size_t *)FUN_00322b40(*param_1 + param_3,param_1[1],param_2);
  psVar1 = (size_t *)PTR_DAT_00457c38;
  __n = *param_1;
  __dest = psVar2 + 3;
  if (__n != 0) {
    if (__n == 1) {
      *(char *)(psVar2 + 3) = (char)param_1[3];
      __n = *param_1;
    }
    else {
      __dest = (size_t *)memcpy(__dest,param_1 + 3,__n);
      __n = *param_1;
      psVar1 = (size_t *)PTR_DAT_00457c38;
    }
  }
  if (psVar2 != psVar1) {
    *(undefined4 *)(psVar2 + 2) = 0;
    *psVar2 = __n;
    *(undefined1 *)((long)psVar2 + __n + 0x18) = 0;
  }
  return __dest;
}

