
/* std::wstring::wstring(std::wstring const&, unsigned long, std::allocator<wchar_t> const&) */

void __thiscall
std::wstring::wstring(wstring *this,wstring *param_1,ulong param_2,allocator *param_3)

{
  long lVar1;
  ulong uVar2;
  wchar_t *pwVar3;
  
  lVar1 = *(long *)param_1;
  uVar2 = *(ulong *)(lVar1 + -0x18);
  if (param_2 <= uVar2) {
    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);
    *(wchar_t **)this = pwVar3;
    return;
  }
                    /* WARNING: Subroutine does not return */
  __throw_out_of_range_fmt
            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",
             param_2,uVar2);
}



void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)

{
  long lVar1;
  ulong uVar2;
  undefined8 uVar3;
  
  lVar1 = *param_2;
  uVar2 = *(ulong *)(lVar1 + -0x18);
  if (param_3 <= uVar2) {
    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);
    *param_1 = uVar3;
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"
               ,param_3,uVar2);
}


PUSH RBX
MOV RAX,qword ptr [RSI]
MOV RBX,RDI
MOV RDI,qword ptr [RAX + -0x18]
LEA RSI,[RAX + RDI*0x4]
CMP RDX,RDI
JA 0x003573e5
LEA RDI,[RAX + RDX*0x4]
MOV RDX,RCX
CALL 0x00357390
MOV qword ptr [RBX],RAX
POP RBX
RET
MOV RCX,RDI
LEA RSI,[0x3911d3]
XOR EAX,EAX
LEA RDI,[0x376b80]
CALL 0x00319610
(translation_unit "void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)\n\n{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}\n\n" (function_definition "void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)\n\n{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" primitive_type (function_declarator "FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" identifier (parameter_list "(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" ( (parameter_declaration "undefined8 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "long *param_2" (sized_type_specifier "long" long) (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "ulong param_3" type_identifier identifier) , (parameter_declaration "undefined8 param_4" type_identifier identifier) ))) (compound_statement "{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" { (declaration "long lVar1;" (sized_type_specifier "long" long) identifier ;) (declaration "ulong uVar2;" type_identifier identifier ;) (declaration "undefined8 uVar3;" type_identifier identifier ;) (expression_statement "lVar1 = *param_2;" (assignment_expression "lVar1 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (expression_statement "uVar2 = *(ulong *)(lVar1 + -0x18);" (assignment_expression "uVar2 = *(ulong *)(lVar1 + -0x18)" identifier = (pointer_expression "*(ulong *)(lVar1 + -0x18)" * (cast_expression "(ulong *)(lVar1 + -0x18)" ( (type_descriptor "ulong *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar1 + -0x18)" ( (binary_expression "lVar1 + -0x18" identifier + number_literal) ))))) ;) (if_statement "if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" if (parenthesized_expression "(param_3 <= uVar2)" ( (binary_expression "param_3 <= uVar2" identifier <= identifier) )) (compound_statement "{\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" { (expression_statement "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);" (assignment_expression "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" identifier = (call_expression "FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" identifier (argument_list "(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" ( (binary_expression "lVar1 + param_3 * 4" identifier + (binary_expression "param_3 * 4" identifier * number_literal)) , (binary_expression "lVar1 + uVar2 * 4" identifier + (binary_expression "uVar2 * 4" identifier * number_literal)) , identifier )))) ;) (expression_statement "*param_1 = uVar3;" (assignment_expression "*param_1 = uVar3" (pointer_expression "*param_1" * identifier) = identifier) ;) (return_statement "return;" return ;) })) comment (expression_statement "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);" (call_expression "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" identifier (argument_list "("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" ( (string_literal ""%s: __pos (which is %zu) > this->size() (which is %zu)"" " string_content ") , (string_literal ""basic_string::basic_string"" " string_content ") , identifier , identifier ))) ;) })))
(translation_unit "/* std::wstring::wstring(std::wstring const&, unsigned long, std::allocator<wchar_t> const&) */\n\nvoid __thiscall\nstd::wstring::wstring(wstring *this,wstring *param_1,ulong param_2,allocator *param_3)\n\n{\n  long lVar1;\n  ulong uVar2;\n  wchar_t *pwVar3;\n  \n  lVar1 = *(long *)param_1;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_2 <= uVar2) {\n    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);\n    *(wchar_t **)this = pwVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __throw_out_of_range_fmt\n            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2);\n}\n\n" comment (function_definition "void __thiscall\nstd::wstring::wstring(wstring *this,wstring *param_1,ulong param_2,allocator *param_3)\n\n{\n  long lVar1;\n  ulong uVar2;\n  wchar_t *pwVar3;\n  \n  lVar1 = *(long *)param_1;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_2 <= uVar2) {\n    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);\n    *(wchar_t **)this = pwVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __throw_out_of_range_fmt\n            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2);\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::wstring::" identifier : : identifier : :) (function_declarator "wstring(wstring *this,wstring *param_1,ulong param_2,allocator *param_3)" identifier (parameter_list "(wstring *this,wstring *param_1,ulong param_2,allocator *param_3)" ( (parameter_declaration "wstring *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "wstring *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "ulong param_2" type_identifier identifier) , (parameter_declaration "allocator *param_3" type_identifier (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  long lVar1;\n  ulong uVar2;\n  wchar_t *pwVar3;\n  \n  lVar1 = *(long *)param_1;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_2 <= uVar2) {\n    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);\n    *(wchar_t **)this = pwVar3;\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __throw_out_of_range_fmt\n            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2);\n}" { (declaration "long lVar1;" (sized_type_specifier "long" long) identifier ;) (declaration "ulong uVar2;" type_identifier identifier ;) (declaration "wchar_t *pwVar3;" type_identifier (pointer_declarator "*pwVar3" * identifier) ;) (expression_statement "lVar1 = *(long *)param_1;" (assignment_expression "lVar1 = *(long *)param_1" identifier = (pointer_expression "*(long *)param_1" * (cast_expression "(long *)param_1" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) identifier))) ;) (expression_statement "uVar2 = *(ulong *)(lVar1 + -0x18);" (assignment_expression "uVar2 = *(ulong *)(lVar1 + -0x18)" identifier = (pointer_expression "*(ulong *)(lVar1 + -0x18)" * (cast_expression "(ulong *)(lVar1 + -0x18)" ( (type_descriptor "ulong *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar1 + -0x18)" ( (binary_expression "lVar1 + -0x18" identifier + number_literal) ))))) ;) (if_statement "if (param_2 <= uVar2) {\n    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);\n    *(wchar_t **)this = pwVar3;\n    return;\n  }" if (parenthesized_expression "(param_2 <= uVar2)" ( (binary_expression "param_2 <= uVar2" identifier <= identifier) )) (compound_statement "{\n    pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);\n    *(wchar_t **)this = pwVar3;\n    return;\n  }" { (expression_statement "pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3);" (assignment_expression "pwVar3 = _S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3)" identifier = (binary_expression "_S_construct<wchar_t*>(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3)" (binary_expression "_S_construct<wchar_t" identifier < identifier) (ERROR "*" *) > (parenthesized_expression "(lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3)" ( (comma_expression "lVar1 + param_2 * 4,lVar1 + uVar2 * 4,param_3" (binary_expression "lVar1 + param_2 * 4" identifier + (binary_expression "param_2 * 4" identifier * number_literal)) , (comma_expression "lVar1 + uVar2 * 4,param_3" (binary_expression "lVar1 + uVar2 * 4" identifier + (binary_expression "uVar2 * 4" identifier * number_literal)) , identifier)) )))) ;) (expression_statement "*(wchar_t **)this = pwVar3;" (assignment_expression "*(wchar_t **)this = pwVar3" (pointer_expression "*(wchar_t **)this" * (cast_expression "(wchar_t **)this" ( (type_descriptor "wchar_t **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = identifier) ;) (return_statement "return;" return ;) })) comment (expression_statement "__throw_out_of_range_fmt\n            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2);" (call_expression "__throw_out_of_range_fmt\n            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2)" identifier (argument_list "("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",\n             param_2,uVar2)" ( (string_literal ""%s: __pos (which is %zu) > this->size() (which is %zu)"" " string_content ") , (string_literal ""basic_string::basic_string"" " string_content ") , identifier , identifier ))) ;) })))
(translation_unit "void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)\n\n{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    \n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}\n\n" (function_definition "void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)\n\n{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    \n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" primitive_type (function_declarator "FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" identifier (parameter_list "(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" ( (parameter_declaration "undefined8 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "long *param_2" (sized_type_specifier "long" long) (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "ulong param_3" type_identifier identifier) , (parameter_declaration "undefined8 param_4" type_identifier identifier) ))) (compound_statement "{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    \n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" { (declaration "long lVar1;" (sized_type_specifier "long" long) identifier ;) (declaration "ulong uVar2;" type_identifier identifier ;) (declaration "undefined8 uVar3;" type_identifier identifier ;) (expression_statement "lVar1 = *param_2;" (assignment_expression "lVar1 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (expression_statement "uVar2 = *(ulong *)(lVar1 + -0x18);" (assignment_expression "uVar2 = *(ulong *)(lVar1 + -0x18)" identifier = (pointer_expression "*(ulong *)(lVar1 + -0x18)" * (cast_expression "(ulong *)(lVar1 + -0x18)" ( (type_descriptor "ulong *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar1 + -0x18)" ( (binary_expression "lVar1 + -0x18" identifier + number_literal) ))))) ;) (if_statement "if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" if (parenthesized_expression "(param_3 <= uVar2)" ( (binary_expression "param_3 <= uVar2" identifier <= identifier) )) (compound_statement "{\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" { (expression_statement "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);" (assignment_expression "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" identifier = (call_expression "FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" identifier (argument_list "(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" ( (binary_expression "lVar1 + param_3 * 4" identifier + (binary_expression "param_3 * 4" identifier * number_literal)) , (binary_expression "lVar1 + uVar2 * 4" identifier + (binary_expression "uVar2 * 4" identifier * number_literal)) , identifier )))) ;) (expression_statement "*param_1 = uVar3;" (assignment_expression "*param_1 = uVar3" (pointer_expression "*param_1" * identifier) = identifier) ;) (return_statement "return;" return ;) })) (expression_statement "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);" (call_expression "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" identifier (argument_list "("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" ( (string_literal ""%s: __pos (which is %zu) > this->size() (which is %zu)"" " string_content ") , (string_literal ""basic_string::basic_string"" " string_content ") , identifier , identifier ))) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration (sized_type_specifier long) (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration (sized_type_specifier long) IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression IDENT + (binary_expression IDENT * LIT)) , (binary_expression IDENT + (binary_expression IDENT * LIT)) , IDENT )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (return_statement return ;) })) (expression_statement (call_expression IDENT (argument_list ( (string_literal " string_content ") , (string_literal " string_content ") , IDENT , IDENT ))) ;) })))
(function_definition "void FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)\n\n{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    \n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" (primitive_type "void") (function_declarator "FUN_003573c0(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" (identifier "FUN_003573c0") (parameter_list "(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)" (( "(") (parameter_declaration "undefined8 *param_1" (type_identifier "undefined8") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "long *param_2" (sized_type_specifier "long" (long "long")) (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "ulong param_3" (type_identifier "ulong") (identifier "param_3")) (, ",") (parameter_declaration "undefined8 param_4" (type_identifier "undefined8") (identifier "param_4")) () ")"))) (compound_statement "{\n  long lVar1;\n  ulong uVar2;\n  undefined8 uVar3;\n  \n  lVar1 = *param_2;\n  uVar2 = *(ulong *)(lVar1 + -0x18);\n  if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }\n                    \n  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);\n}" ({ "{") (declaration "long lVar1;" (sized_type_specifier "long" (long "long")) (identifier "lVar1") (; ";")) (declaration "ulong uVar2;" (type_identifier "ulong") (identifier "uVar2") (; ";")) (declaration "undefined8 uVar3;" (type_identifier "undefined8") (identifier "uVar3") (; ";")) (expression_statement "lVar1 = *param_2;" (assignment_expression "lVar1 = *param_2" (identifier "lVar1") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (expression_statement "uVar2 = *(ulong *)(lVar1 + -0x18);" (assignment_expression "uVar2 = *(ulong *)(lVar1 + -0x18)" (identifier "uVar2") (= "=") (pointer_expression "*(ulong *)(lVar1 + -0x18)" (* "*") (cast_expression "(ulong *)(lVar1 + -0x18)" (( "(") (type_descriptor "ulong *" (type_identifier "ulong") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(lVar1 + -0x18)" (( "(") (binary_expression "lVar1 + -0x18" (identifier "lVar1") (+ "+") (number_literal "-0x18")) () ")"))))) (; ";")) (if_statement "if (param_3 <= uVar2) {\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" (if "if") (parenthesized_expression "(param_3 <= uVar2)" (( "(") (binary_expression "param_3 <= uVar2" (identifier "param_3") (<= "<=") (identifier "uVar2")) () ")")) (compound_statement "{\n    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);\n    *param_1 = uVar3;\n    return;\n  }" ({ "{") (expression_statement "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);" (assignment_expression "uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" (identifier "uVar3") (= "=") (call_expression "FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" (identifier "FUN_00357390") (argument_list "(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4)" (( "(") (binary_expression "lVar1 + param_3 * 4" (identifier "lVar1") (+ "+") (binary_expression "param_3 * 4" (identifier "param_3") (* "*") (number_literal "4"))) (, ",") (binary_expression "lVar1 + uVar2 * 4" (identifier "lVar1") (+ "+") (binary_expression "uVar2 * 4" (identifier "uVar2") (* "*") (number_literal "4"))) (, ",") (identifier "param_4") () ")")))) (; ";")) (expression_statement "*param_1 = uVar3;" (assignment_expression "*param_1 = uVar3" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (identifier "uVar3")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2);" (call_expression "FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" (identifier "FUN_00319610") (argument_list "("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"\n               ,param_3,uVar2)" (( "(") (string_literal ""%s: __pos (which is %zu) > this->size() (which is %zu)"" (" """) (string_content "%s: __pos (which is %zu) > this->size() (which is %zu)") (" """)) (, ",") (string_literal ""basic_string::basic_string"" (" """) (string_content "basic_string::basic_string") (" """)) (, ",") (identifier "param_3") (, ",") (identifier "uVar2") () ")"))) (; ";")) (} "}")))

/* std::wstring::wstring(std::wstring const&, unsigned long, std::allocator<wchar_t> const&) */

void __thiscall
std::function_1::function_1(function_1 *this,function_1 *param_1,type_1 var_2,type_2 *param_3)

{
  long var_1;
  type_1 var_3;
  type_3 *pwVar3;
  
  var_1 = *(long *)param_1;
  var_3 = *(type_1 *)(var_1 + -0x18);
  if (var_2 <= var_3) {
    pwVar3 = var_4<type_3*>(var_1 + var_2 * 4,var_1 + var_3 * 4,param_3);
    *(type_3 **)this = pwVar3;
    return;
  }
                    /* WARNING: Subroutine does not return */
  var_5
            ("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string",
             var_2,var_3);
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (sized_type_specifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (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: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))) (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))) (identifier))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (return_statement))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (string_literal (string_content)) (string_literal (string_content)) (identifier) (identifier)))))))

void MASKED(undefined8 *param_1,long *param_2,ulong param_3,undefined8 param_4)

{
  long lVar1;
  ulong uVar2;
  undefined8 uVar3;
  
  lVar1 = *param_2;
  uVar2 = *(ulong *)(lVar1 + -0x18);
  if (param_3 <= uVar2) {
    uVar3 = FUN_00357390(lVar1 + param_3 * 4,lVar1 + uVar2 * 4,param_4);
    *param_1 = uVar3;
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_00319610("%s: __pos (which is %zu) > this->size() (which is %zu)","basic_string::basic_string"
               ,param_3,uVar2);
}

