
/* std::__codecvt_utf8_base<char16_t>::do_out(__mbstate_t&, char16_t const*, char16_t const*,
   char16_t const*&, char*, char*, char*&) const */

undefined4 __thiscall
std::__codecvt_utf8_base<char16_t>::do_out
          (__codecvt_utf8_base<char16_t> *this,__mbstate_t *param_1,wchar16 *param_2,
          wchar16 *param_3,wchar16 **param_4,char *param_5,char *param_6,char **param_7)

{
  char cVar1;
  undefined4 uVar2;
  uint uVar3;
  wchar16 *local_18;
  wchar16 *local_14;
  char *local_10;
  char *local_c;
  
  local_18 = param_2;
  uVar3 = *(uint *)(this + 8);
  local_14 = param_3;
  local_10 = param_5;
  local_c = param_6;
  if (0xfffe < uVar3) {
    uVar3 = 0xffff;
  }
  if (((byte)this[0xc] & 2) != 0) {
    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);
    if (cVar1 == '\0') {
      uVar2 = 1;
      goto LAB_0026e4bc;
    }
  }
  uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1);
LAB_0026e4bc:
  *param_4 = local_18;
  *param_7 = local_10;
  return uVar2;
}



undefined4
FUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,
            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)

{
  char cVar1;
  undefined4 uVar2;
  
  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||
     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {
    uVar2 = FUN_0026e3b0(1);
  }
  else {
    uVar2 = 1;
  }
  *param_5 = param_3;
  *param_8 = param_6;
  return uVar2;
}


PUSH ESI
PUSH EBX
SUB ESP,0x10
MOV EDX,dword ptr [ESP + 0x24]
MOV EAX,dword ptr [ESP + 0x1c]
LEA ESI,[ESP + 0x8]
MOV dword ptr [ESP],EDX
MOV EDX,dword ptr [ESP + 0x28]
MOV EBX,dword ptr [EAX + 0x8]
MOV dword ptr [ESP + 0x4],EDX
MOV EDX,dword ptr [ESP + 0x30]
CMP EBX,0xffff
MOV dword ptr [ESP + 0x8],EDX
MOV EDX,dword ptr [ESP + 0x34]
MOV dword ptr [ESP + 0xc],EDX
MOV EDX,0xffff
CMOVNC EBX,EDX
TEST byte ptr [EAX + 0xc],0x2
JZ 0x0026e4ae
MOV EAX,ESI
CALL 0x0026e370
TEST AL,AL
JZ 0x0026e4d8
MOV EAX,ESP
PUSH 0x1
MOV EDX,ESI
MOV ECX,EBX
CALL 0x0026e3b0
POP EDX
MOV EDX,dword ptr [ESP + 0x2c]
MOV ECX,dword ptr [ESP]
MOV dword ptr [EDX],ECX
MOV EDX,dword ptr [ESP + 0x38]
MOV ECX,dword ptr [ESP + 0x8]
MOV dword ptr [EDX],ECX
ADD ESP,0x10
POP EBX
POP ESI
RET
MOV EAX,0x1
JMP 0x0026e4bc
(translation_unit "undefined4\nFUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}\n\n" (function_definition "undefined4\nFUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" type_identifier (function_declarator "FUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "undefined4 *param_5" type_identifier (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "undefined4 *param_8" type_identifier (pointer_declarator "*param_8" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (if_statement "if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }" if (parenthesized_expression "(((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'))" ( (binary_expression "((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" (parenthesized_expression "((*(byte *)(param_1 + 0xc) & 2) == 0)" ( (binary_expression "(*(byte *)(param_1 + 0xc) & 2) == 0" (parenthesized_expression "(*(byte *)(param_1 + 0xc) & 2)" ( (binary_expression "*(byte *)(param_1 + 0xc) & 2" (pointer_expression "*(byte *)(param_1 + 0xc)" * (cast_expression "(byte *)(param_1 + 0xc)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) & number_literal) )) == number_literal) )) || (parenthesized_expression "(cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" ( (comma_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'" (assignment_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7)" identifier = (call_expression "FUN_0026e370(param_3,param_4,param_6,param_7)" identifier (argument_list "(param_3,param_4,param_6,param_7)" ( identifier , identifier , identifier , identifier )))) , (binary_expression "cVar1 != '\0'" identifier != (char_literal "'\0'" ' escape_sequence '))) ))) )) (compound_statement "{\n    uVar2 = FUN_0026e3b0(1);\n  }" { (expression_statement "uVar2 = FUN_0026e3b0(1);" (assignment_expression "uVar2 = FUN_0026e3b0(1)" identifier = (call_expression "FUN_0026e3b0(1)" identifier (argument_list "(1)" ( number_literal )))) ;) }) (else_clause "else {\n    uVar2 = 1;\n  }" else (compound_statement "{\n    uVar2 = 1;\n  }" { (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" identifier = number_literal) ;) }))) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" * identifier) = identifier) ;) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "/* std::__codecvt_utf8_base<char16_t>::do_out(__mbstate_t&, char16_t const*, char16_t const*,\n   char16_t const*&, char*, char*, char*&) const */\n\nundefined4 __thiscall\nstd::__codecvt_utf8_base<char16_t>::do_out\n          (__codecvt_utf8_base<char16_t> *this,__mbstate_t *param_1,wchar16 *param_2,\n          wchar16 *param_3,wchar16 **param_4,char *param_5,char *param_6,char **param_7)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  uint uVar3;\n  wchar16 *local_18;\n  wchar16 *local_14;\n  char *local_10;\n  char *local_c;\n  \n  local_18 = param_2;\n  uVar3 = *(uint *)(this + 8);\n  local_14 = param_3;\n  local_10 = param_5;\n  local_c = param_6;\n  if (0xfffe < uVar3) {\n    uVar3 = 0xffff;\n  }\n  if (((byte)this[0xc] & 2) != 0) {\n    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);\n    if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }\n  }\n  uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1);\nLAB_0026e4bc:\n  *param_4 = local_18;\n  *param_7 = local_10;\n  return uVar2;\n}\n\n" comment (function_definition "undefined4 __thiscall\nstd::__codecvt_utf8_base<char16_t>::do_out\n          (__codecvt_utf8_base<char16_t> *this,__mbstate_t *param_1,wchar16 *param_2,\n          wchar16 *param_3,wchar16 **param_4,char *param_5,char *param_6,char **param_7)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  uint uVar3;\n  wchar16 *local_18;\n  wchar16 *local_14;\n  char *local_10;\n  char *local_c;\n  \n  local_18 = param_2;\n  uVar3 = *(uint *)(this + 8);\n  local_14 = param_3;\n  local_10 = param_5;\n  local_c = param_6;\n  if (0xfffe < uVar3) {\n    uVar3 = 0xffff;\n  }\n  if (((byte)this[0xc] & 2) != 0) {\n    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);\n    if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }\n  }\n  uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1);\nLAB_0026e4bc:\n  *param_4 = local_18;\n  *param_7 = local_10;\n  return uVar2;\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::__codecvt_utf8_base<char16_t>::" identifier : : identifier < primitive_type > : :) (function_declarator "do_out\n          (__codecvt_utf8_base<char16_t> *this,__mbstate_t *param_1,wchar16 *param_2,\n          wchar16 *param_3,wchar16 **param_4,char *param_5,char *param_6,char **param_7)" identifier (parameter_list "(__codecvt_utf8_base<char16_t> *this,__mbstate_t *param_1,wchar16 *param_2,\n          wchar16 *param_3,wchar16 **param_4,char *param_5,char *param_6,char **param_7)" ( (parameter_declaration "__codecvt_utf8_base<char16_t> *this" type_identifier (ERROR "<char16_t>" < primitive_type >) (pointer_declarator "*this" * identifier)) , (parameter_declaration "__mbstate_t *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "wchar16 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "wchar16 *param_3" type_identifier (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "wchar16 **param_4" type_identifier (pointer_declarator "**param_4" * (pointer_declarator "*param_4" * identifier))) , (parameter_declaration "char *param_5" primitive_type (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "char *param_6" primitive_type (pointer_declarator "*param_6" * identifier)) , (parameter_declaration "char **param_7" primitive_type (pointer_declarator "**param_7" * (pointer_declarator "*param_7" * identifier))) ))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  uint uVar3;\n  wchar16 *local_18;\n  wchar16 *local_14;\n  char *local_10;\n  char *local_c;\n  \n  local_18 = param_2;\n  uVar3 = *(uint *)(this + 8);\n  local_14 = param_3;\n  local_10 = param_5;\n  local_c = param_6;\n  if (0xfffe < uVar3) {\n    uVar3 = 0xffff;\n  }\n  if (((byte)this[0xc] & 2) != 0) {\n    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);\n    if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }\n  }\n  uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1);\nLAB_0026e4bc:\n  *param_4 = local_18;\n  *param_7 = local_10;\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "wchar16 *local_18;" type_identifier (pointer_declarator "*local_18" * identifier) ;) (declaration "wchar16 *local_14;" type_identifier (pointer_declarator "*local_14" * identifier) ;) (declaration "char *local_10;" primitive_type (pointer_declarator "*local_10" * identifier) ;) (declaration "char *local_c;" primitive_type (pointer_declarator "*local_c" * identifier) ;) (expression_statement "local_18 = param_2;" (assignment_expression "local_18 = param_2" identifier = identifier) ;) (expression_statement "uVar3 = *(uint *)(this + 8);" (assignment_expression "uVar3 = *(uint *)(this + 8)" identifier = (pointer_expression "*(uint *)(this + 8)" * (cast_expression "(uint *)(this + 8)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) ))))) ;) (expression_statement "local_14 = param_3;" (assignment_expression "local_14 = param_3" identifier = identifier) ;) (expression_statement "local_10 = param_5;" (assignment_expression "local_10 = param_5" identifier = identifier) ;) (expression_statement "local_c = param_6;" (assignment_expression "local_c = param_6" identifier = identifier) ;) (if_statement "if (0xfffe < uVar3) {\n    uVar3 = 0xffff;\n  }" if (parenthesized_expression "(0xfffe < uVar3)" ( (binary_expression "0xfffe < uVar3" number_literal < identifier) )) (compound_statement "{\n    uVar3 = 0xffff;\n  }" { (expression_statement "uVar3 = 0xffff;" (assignment_expression "uVar3 = 0xffff" identifier = number_literal) ;) })) (if_statement "if (((byte)this[0xc] & 2) != 0) {\n    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);\n    if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }\n  }" if (parenthesized_expression "(((byte)this[0xc] & 2) != 0)" ( (binary_expression "((byte)this[0xc] & 2) != 0" (parenthesized_expression "((byte)this[0xc] & 2)" ( (binary_expression "(byte)this[0xc] & 2" (cast_expression "(byte)this[0xc]" ( (type_descriptor "byte" type_identifier) ) (subscript_expression "this[0xc]" identifier [ number_literal ])) & number_literal) )) != number_literal) )) (compound_statement "{\n    cVar1 = (anonymous_namespace)::write_utf8_bom(&local_10);\n    if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }\n  }" { (ERROR "cVar1 = (anonymous_namespace)::" (assignment_expression "cVar1 = (anonymous_namespace)" identifier = (parenthesized_expression "(anonymous_namespace)" ( identifier ))) : :) (expression_statement "write_utf8_bom(&local_10);" (call_expression "write_utf8_bom(&local_10)" identifier (argument_list "(&local_10)" ( (pointer_expression "&local_10" & identifier) ))) ;) (if_statement "if (cVar1 == '\0') {\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }" if (parenthesized_expression "(cVar1 == '\0')" ( (binary_expression "cVar1 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      uVar2 = 1;\n      goto LAB_0026e4bc;\n    }" { (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" identifier = number_literal) ;) (goto_statement "goto LAB_0026e4bc;" goto statement_identifier ;) })) })) (expression_statement "uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1);" (binary_expression "uVar2 = (anonymous_namespace)::utf16_out<char16_t>(&local_18,&local_10,uVar3,1)" (binary_expression "uVar2 = (anonymous_namespace)::utf16_out<char16_t" (assignment_expression "uVar2 = (anonymous_namespace)" identifier = (parenthesized_expression "(anonymous_namespace)" ( identifier ))) (ERROR "::utf16_out" : : identifier) < identifier) > (parenthesized_expression "(&local_18,&local_10,uVar3,1)" ( (comma_expression "&local_18,&local_10,uVar3,1" (pointer_expression "&local_18" & identifier) , (comma_expression "&local_10,uVar3,1" (pointer_expression "&local_10" & identifier) , (comma_expression "uVar3,1" identifier , number_literal))) ))) ;) (labeled_statement "LAB_0026e4bc:\n  *param_4 = local_18;" statement_identifier : (expression_statement "*param_4 = local_18;" (assignment_expression "*param_4 = local_18" (pointer_expression "*param_4" * identifier) = identifier) ;)) (expression_statement "*param_7 = local_10;" (assignment_expression "*param_7 = local_10" (pointer_expression "*param_7" * identifier) = identifier) ;) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "undefined4\nFUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}\n\n" (function_definition "undefined4\nFUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" type_identifier (function_declarator "FUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "undefined4 *param_5" type_identifier (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "undefined4 *param_8" type_identifier (pointer_declarator "*param_8" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (if_statement "if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }" if (parenthesized_expression "(((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'))" ( (binary_expression "((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" (parenthesized_expression "((*(byte *)(param_1 + 0xc) & 2) == 0)" ( (binary_expression "(*(byte *)(param_1 + 0xc) & 2) == 0" (parenthesized_expression "(*(byte *)(param_1 + 0xc) & 2)" ( (binary_expression "*(byte *)(param_1 + 0xc) & 2" (pointer_expression "*(byte *)(param_1 + 0xc)" * (cast_expression "(byte *)(param_1 + 0xc)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) & number_literal) )) == number_literal) )) || (parenthesized_expression "(cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" ( (comma_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'" (assignment_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7)" identifier = (call_expression "FUN_0026e370(param_3,param_4,param_6,param_7)" identifier (argument_list "(param_3,param_4,param_6,param_7)" ( identifier , identifier , identifier , identifier )))) , (binary_expression "cVar1 != '\0'" identifier != (char_literal "'\0'" ' escape_sequence '))) ))) )) (compound_statement "{\n    uVar2 = FUN_0026e3b0(1);\n  }" { (expression_statement "uVar2 = FUN_0026e3b0(1);" (assignment_expression "uVar2 = FUN_0026e3b0(1)" identifier = (call_expression "FUN_0026e3b0(1)" identifier (argument_list "(1)" ( number_literal )))) ;) }) (else_clause "else {\n    uVar2 = 1;\n  }" else (compound_statement "{\n    uVar2 = 1;\n  }" { (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" identifier = number_literal) ;) }))) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" * identifier) = identifier) ;) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) == LIT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT , IDENT )))) , (binary_expression IDENT != (char_literal ' escape_sequence '))) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT )))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }))) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (return_statement return IDENT ;) })))
(function_definition "undefined4\nFUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" (type_identifier "undefined4") (function_declarator "FUN_0026e460(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" (identifier "FUN_0026e460") (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,\n            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) (, ",") (parameter_declaration "undefined4 param_4" (type_identifier "undefined4") (identifier "param_4")) (, ",") (parameter_declaration "undefined4 *param_5" (type_identifier "undefined4") (pointer_declarator "*param_5" (* "*") (identifier "param_5"))) (, ",") (parameter_declaration "undefined4 param_6" (type_identifier "undefined4") (identifier "param_6")) (, ",") (parameter_declaration "undefined4 param_7" (type_identifier "undefined4") (identifier "param_7")) (, ",") (parameter_declaration "undefined4 *param_8" (type_identifier "undefined4") (pointer_declarator "*param_8" (* "*") (identifier "param_8"))) () ")"))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  \n  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }\n  *param_5 = param_3;\n  *param_8 = param_6;\n  return uVar2;\n}" ({ "{") (declaration "char cVar1;" (primitive_type "char") (identifier "cVar1") (; ";")) (declaration "undefined4 uVar2;" (type_identifier "undefined4") (identifier "uVar2") (; ";")) (if_statement "if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {\n    uVar2 = FUN_0026e3b0(1);\n  }\n  else {\n    uVar2 = 1;\n  }" (if "if") (parenthesized_expression "(((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'))" (( "(") (binary_expression "((*(byte *)(param_1 + 0xc) & 2) == 0) ||\n     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" (parenthesized_expression "((*(byte *)(param_1 + 0xc) & 2) == 0)" (( "(") (binary_expression "(*(byte *)(param_1 + 0xc) & 2) == 0" (parenthesized_expression "(*(byte *)(param_1 + 0xc) & 2)" (( "(") (binary_expression "*(byte *)(param_1 + 0xc) & 2" (pointer_expression "*(byte *)(param_1 + 0xc)" (* "*") (cast_expression "(byte *)(param_1 + 0xc)" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (& "&") (number_literal "2")) () ")")) (== "==") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "(cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')" (( "(") (comma_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0'" (assignment_expression "cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7)" (identifier "cVar1") (= "=") (call_expression "FUN_0026e370(param_3,param_4,param_6,param_7)" (identifier "FUN_0026e370") (argument_list "(param_3,param_4,param_6,param_7)" (( "(") (identifier "param_3") (, ",") (identifier "param_4") (, ",") (identifier "param_6") (, ",") (identifier "param_7") () ")")))) (, ",") (binary_expression "cVar1 != '\0'" (identifier "cVar1") (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'")))) () ")"))) () ")")) (compound_statement "{\n    uVar2 = FUN_0026e3b0(1);\n  }" ({ "{") (expression_statement "uVar2 = FUN_0026e3b0(1);" (assignment_expression "uVar2 = FUN_0026e3b0(1)" (identifier "uVar2") (= "=") (call_expression "FUN_0026e3b0(1)" (identifier "FUN_0026e3b0") (argument_list "(1)" (( "(") (number_literal "1") () ")")))) (; ";")) (} "}")) (else_clause "else {\n    uVar2 = 1;\n  }" (else "else") (compound_statement "{\n    uVar2 = 1;\n  }" ({ "{") (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" (identifier "uVar2") (= "=") (number_literal "1")) (; ";")) (} "}")))) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" (* "*") (identifier "param_5")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (identifier "param_6")) (; ";")) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

/* std::__codecvt_utf8_base<char16_t>::do_out(__mbstate_t&, char16_t const*, char16_t const*,
   char16_t const*&, char*, char*, char*&) const */

type_1 __thiscall
std::type_2<char16_t>::function_1
          (type_2<char16_t> *var_1,type_3 *param_1,type_4 *param_2,
          type_4 *param_3,type_4 **param_4,char *param_5,char *param_6,char **param_7)

{
  char var_4;
  type_1 uVar2;
  type_5 var_2;
  type_4 *local_18;
  type_4 *local_14;
  char *local_10;
  char *local_c;
  
  local_18 = param_2;
  var_2 = *(type_5 *)(var_1 + 8);
  local_14 = param_3;
  local_10 = param_5;
  local_c = param_6;
  if (0xfffe < var_2) {
    var_2 = 0xffff;
  }
  if (((type_6)var_1[0xc] & 2) != 0) {
    var_4 = (anonymous_namespace)::var_3(&local_10);
    if (var_4 == '\0') {
      uVar2 = 1;
      goto LAB_0026e4bc;
    }
  }
  uVar2 = (anonymous_namespace)::utf16_out<var_5>(&local_18,&local_10,var_2,1);
LAB_0026e4bc:
  *param_4 = local_18;
  *param_7 = local_10;
  return uVar2;
}


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

undefined4
MASKED(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,
            undefined4 *param_5,undefined4 param_6,undefined4 param_7,undefined4 *param_8)

{
  char cVar1;
  undefined4 uVar2;
  
  if (((*(byte *)(param_1 + 0xc) & 2) == 0) ||
     (cVar1 = FUN_0026e370(param_3,param_4,param_6,param_7), cVar1 != '\0')) {
    uVar2 = FUN_0026e3b0(1);
  }
  else {
    uVar2 = 1;
  }
  *param_5 = param_3;
  *param_8 = param_6;
  return uVar2;
}

