
/* std::messages<char>::do_open(std::string const&, std::locale const&) const */

undefined4 __thiscall
std::messages<char>::do_open(messages<char> *this,string *param_1,locale *param_2)

{
  undefined4 uVar1;
  codecvt *pcVar2;
  undefined8 uVar3;
  Catalogs *pCVar4;
  locale local_30 [16];
  
  pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2);
  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10));
  bind_textdomain_codeset(*(undefined8 *)param_1,uVar3);
  pCVar4 = (Catalogs *)get_catalogs();
  locale::locale(local_30,param_2);
                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */
  uVar1 = Catalogs::_M_add(pCVar4,*(undefined8 *)param_1,local_30);
  locale::~locale(local_30);
  return uVar1;
}



undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)

{
  undefined4 uVar1;
  long lVar2;
  undefined8 uVar3;
  undefined1 local_30 [16];
  
  lVar2 = FUN_002ecd20(param_3);
  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));
  bind_textdomain_codeset(*param_2,uVar3);
  uVar3 = FUN_0031be80();
  FUN_002dca70(local_30,param_3);
                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */
  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);
  FUN_002dd1b0(local_30);
  return uVar1;
}


PUSH R13
MOV RDI,RDX
PUSH R12
MOV R12,RDX
PUSH RBP
MOV RBP,RSI
PUSH RBX
SUB RSP,0x18
CALL 0x002ecd20
MOV EDI,0xe
LEA RBX,[RSP + 0x8]
MOV RSI,qword ptr [RAX + 0x10]
CALL 0x001470b0
MOV RDI,qword ptr [RBP]
MOV RSI,RAX
CALL 0x00147930
CALL 0x0031be80
MOV RSI,R12
MOV RDI,RBX
MOV R13,RAX
CALL 0x002dca70
MOV RSI,qword ptr [RBP]
MOV RDX,RBX
MOV RDI,R13
CALL 0x0031c090
MOV RDI,RBX
MOV EBP,EAX
CALL 0x002dd1b0
ADD RSP,0x18
MOV EAX,EBP
POP RBX
POP RBP
POP R12
POP R13
RET
(translation_unit "undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)\n\n{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}\n\n" (function_definition "undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)\n\n{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" type_identifier (function_declarator "FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" identifier (parameter_list "(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" ( (parameter_declaration "undefined8 param_1" type_identifier identifier) , (parameter_declaration "undefined8 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "undefined8 param_3" type_identifier identifier) ))) (compound_statement "{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "long lVar2;" (sized_type_specifier "long" long) identifier ;) (declaration "undefined8 uVar3;" type_identifier identifier ;) (declaration "undefined1 local_30 [16];" type_identifier (array_declarator "local_30 [16]" identifier [ number_literal ]) ;) (expression_statement "lVar2 = FUN_002ecd20(param_3);" (assignment_expression "lVar2 = FUN_002ecd20(param_3)" identifier = (call_expression "FUN_002ecd20(param_3)" identifier (argument_list "(param_3)" ( identifier )))) ;) (expression_statement "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));" (assignment_expression "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" identifier = (call_expression "__nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" identifier (argument_list "(0xe,*(undefined8 *)(lVar2 + 0x10))" ( number_literal , (pointer_expression "*(undefined8 *)(lVar2 + 0x10)" * (cast_expression "(undefined8 *)(lVar2 + 0x10)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar2 + 0x10)" ( (binary_expression "lVar2 + 0x10" identifier + number_literal) )))) )))) ;) (expression_statement "bind_textdomain_codeset(*param_2,uVar3);" (call_expression "bind_textdomain_codeset(*param_2,uVar3)" identifier (argument_list "(*param_2,uVar3)" ( (pointer_expression "*param_2" * identifier) , identifier ))) ;) (expression_statement "uVar3 = FUN_0031be80();" (assignment_expression "uVar3 = FUN_0031be80()" identifier = (call_expression "FUN_0031be80()" identifier (argument_list "()" ( )))) ;) (expression_statement "FUN_002dca70(local_30,param_3);" (call_expression "FUN_002dca70(local_30,param_3)" identifier (argument_list "(local_30,param_3)" ( identifier , identifier ))) ;) comment (expression_statement "uVar1 = FUN_0031c090(uVar3,*param_2,local_30);" (assignment_expression "uVar1 = FUN_0031c090(uVar3,*param_2,local_30)" identifier = (call_expression "FUN_0031c090(uVar3,*param_2,local_30)" identifier (argument_list "(uVar3,*param_2,local_30)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier )))) ;) (expression_statement "FUN_002dd1b0(local_30);" (call_expression "FUN_002dd1b0(local_30)" identifier (argument_list "(local_30)" ( identifier ))) ;) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit "/* std::messages<char>::do_open(std::string const&, std::locale const&) const */\n\nundefined4 __thiscall\nstd::messages<char>::do_open(messages<char> *this,string *param_1,locale *param_2)\n\n{\n  undefined4 uVar1;\n  codecvt *pcVar2;\n  undefined8 uVar3;\n  Catalogs *pCVar4;\n  locale local_30 [16];\n  \n  pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10));\n  bind_textdomain_codeset(*(undefined8 *)param_1,uVar3);\n  pCVar4 = (Catalogs *)get_catalogs();\n  locale::locale(local_30,param_2);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = Catalogs::_M_add(pCVar4,*(undefined8 *)param_1,local_30);\n  locale::~locale(local_30);\n  return uVar1;\n}\n\n" comment (function_definition "undefined4 __thiscall\nstd::messages<char>::do_open(messages<char> *this,string *param_1,locale *param_2)\n\n{\n  undefined4 uVar1;\n  codecvt *pcVar2;\n  undefined8 uVar3;\n  Catalogs *pCVar4;\n  locale local_30 [16];\n  \n  pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10));\n  bind_textdomain_codeset(*(undefined8 *)param_1,uVar3);\n  pCVar4 = (Catalogs *)get_catalogs();\n  locale::locale(local_30,param_2);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = Catalogs::_M_add(pCVar4,*(undefined8 *)param_1,local_30);\n  locale::~locale(local_30);\n  return uVar1;\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::messages<char>::" identifier : : identifier < primitive_type > : :) (function_declarator "do_open(messages<char> *this,string *param_1,locale *param_2)" identifier (parameter_list "(messages<char> *this,string *param_1,locale *param_2)" ( (parameter_declaration "messages<char> *this" type_identifier (ERROR "<char>" < primitive_type >) (pointer_declarator "*this" * identifier)) , (parameter_declaration "string *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "locale *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  codecvt *pcVar2;\n  undefined8 uVar3;\n  Catalogs *pCVar4;\n  locale local_30 [16];\n  \n  pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10));\n  bind_textdomain_codeset(*(undefined8 *)param_1,uVar3);\n  pCVar4 = (Catalogs *)get_catalogs();\n  locale::locale(local_30,param_2);\n                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */\n  uVar1 = Catalogs::_M_add(pCVar4,*(undefined8 *)param_1,local_30);\n  locale::~locale(local_30);\n  return uVar1;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "codecvt *pcVar2;" type_identifier (pointer_declarator "*pcVar2" * identifier) ;) (declaration "undefined8 uVar3;" type_identifier identifier ;) (declaration "Catalogs *pCVar4;" type_identifier (pointer_declarator "*pCVar4" * identifier) ;) (declaration "locale local_30 [16];" type_identifier (array_declarator "local_30 [16]" identifier [ number_literal ]) ;) (expression_statement "pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2);" (comma_expression "pcVar2 = use_facet<std::codecvt<char,char,__mbstate_t>>(param_2)" (binary_expression "pcVar2 = use_facet<std::codecvt<char" (assignment_expression "pcVar2 = use_facet<std" identifier = (binary_expression "use_facet<std" identifier < identifier)) (ERROR "::codecvt" : : identifier) < identifier) , (comma_expression "char,__mbstate_t>>(param_2)" identifier , (binary_expression "__mbstate_t>>(param_2)" identifier >> (parenthesized_expression "(param_2)" ( identifier ))))) ;) (expression_statement "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10));" (assignment_expression "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10))" identifier = (call_expression "__nl_langinfo_l(0xe,*(undefined8 *)(pcVar2 + 0x10))" identifier (argument_list "(0xe,*(undefined8 *)(pcVar2 + 0x10))" ( number_literal , (pointer_expression "*(undefined8 *)(pcVar2 + 0x10)" * (cast_expression "(undefined8 *)(pcVar2 + 0x10)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pcVar2 + 0x10)" ( (binary_expression "pcVar2 + 0x10" identifier + number_literal) )))) )))) ;) (expression_statement "bind_textdomain_codeset(*(undefined8 *)param_1,uVar3);" (call_expression "bind_textdomain_codeset(*(undefined8 *)param_1,uVar3)" identifier (argument_list "(*(undefined8 *)param_1,uVar3)" ( (pointer_expression "*(undefined8 *)param_1" * (cast_expression "(undefined8 *)param_1" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , identifier ))) ;) (expression_statement "pCVar4 = (Catalogs *)get_catalogs();" (assignment_expression "pCVar4 = (Catalogs *)get_catalogs()" identifier = (cast_expression "(Catalogs *)get_catalogs()" ( (type_descriptor "Catalogs *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "get_catalogs()" identifier (argument_list "()" ( ))))) ;) (labeled_statement "locale::locale(local_30,param_2);" statement_identifier : (ERROR ":" :) (expression_statement "locale(local_30,param_2);" (call_expression "locale(local_30,param_2)" identifier (argument_list "(local_30,param_2)" ( identifier , identifier ))) ;)) comment (ERROR "uVar1 = Catalogs::" (assignment_expression "uVar1 = Catalogs" identifier = identifier) : :) (expression_statement "_M_add(pCVar4,*(undefined8 *)param_1,local_30);" (call_expression "_M_add(pCVar4,*(undefined8 *)param_1,local_30)" identifier (argument_list "(pCVar4,*(undefined8 *)param_1,local_30)" ( identifier , (pointer_expression "*(undefined8 *)param_1" * (cast_expression "(undefined8 *)param_1" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , identifier ))) ;) (labeled_statement "locale::~locale(local_30);" statement_identifier : (ERROR ":" :) (expression_statement "~locale(local_30);" (unary_expression "~locale(local_30)" ~ (call_expression "locale(local_30)" identifier (argument_list "(local_30)" ( identifier )))) ;)) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit "undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)\n\n{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    \n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}\n\n" (function_definition "undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)\n\n{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    \n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" type_identifier (function_declarator "FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" identifier (parameter_list "(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" ( (parameter_declaration "undefined8 param_1" type_identifier identifier) , (parameter_declaration "undefined8 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "undefined8 param_3" type_identifier identifier) ))) (compound_statement "{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    \n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "long lVar2;" (sized_type_specifier "long" long) identifier ;) (declaration "undefined8 uVar3;" type_identifier identifier ;) (declaration "undefined1 local_30 [16];" type_identifier (array_declarator "local_30 [16]" identifier [ number_literal ]) ;) (expression_statement "lVar2 = FUN_002ecd20(param_3);" (assignment_expression "lVar2 = FUN_002ecd20(param_3)" identifier = (call_expression "FUN_002ecd20(param_3)" identifier (argument_list "(param_3)" ( identifier )))) ;) (expression_statement "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));" (assignment_expression "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" identifier = (call_expression "__nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" identifier (argument_list "(0xe,*(undefined8 *)(lVar2 + 0x10))" ( number_literal , (pointer_expression "*(undefined8 *)(lVar2 + 0x10)" * (cast_expression "(undefined8 *)(lVar2 + 0x10)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar2 + 0x10)" ( (binary_expression "lVar2 + 0x10" identifier + number_literal) )))) )))) ;) (expression_statement "bind_textdomain_codeset(*param_2,uVar3);" (call_expression "bind_textdomain_codeset(*param_2,uVar3)" identifier (argument_list "(*param_2,uVar3)" ( (pointer_expression "*param_2" * identifier) , identifier ))) ;) (expression_statement "uVar3 = FUN_0031be80();" (assignment_expression "uVar3 = FUN_0031be80()" identifier = (call_expression "FUN_0031be80()" identifier (argument_list "()" ( )))) ;) (expression_statement "FUN_002dca70(local_30,param_3);" (call_expression "FUN_002dca70(local_30,param_3)" identifier (argument_list "(local_30,param_3)" ( identifier , identifier ))) ;) (expression_statement "uVar1 = FUN_0031c090(uVar3,*param_2,local_30);" (assignment_expression "uVar1 = FUN_0031c090(uVar3,*param_2,local_30)" identifier = (call_expression "FUN_0031c090(uVar3,*param_2,local_30)" identifier (argument_list "(uVar3,*param_2,local_30)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier )))) ;) (expression_statement "FUN_002dd1b0(local_30);" (call_expression "FUN_002dd1b0(local_30)" identifier (argument_list "(local_30)" ( identifier ))) ;) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration (sized_type_specifier long) IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) )))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * IDENT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * IDENT) , IDENT )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (return_statement return IDENT ;) })))
(function_definition "undefined4 FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)\n\n{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    \n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" (type_identifier "undefined4") (function_declarator "FUN_003653f0(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" (identifier "FUN_003653f0") (parameter_list "(undefined8 param_1,undefined8 *param_2,undefined8 param_3)" (( "(") (parameter_declaration "undefined8 param_1" (type_identifier "undefined8") (identifier "param_1")) (, ",") (parameter_declaration "undefined8 *param_2" (type_identifier "undefined8") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "undefined8 param_3" (type_identifier "undefined8") (identifier "param_3")) () ")"))) (compound_statement "{\n  undefined4 uVar1;\n  long lVar2;\n  undefined8 uVar3;\n  undefined1 local_30 [16];\n  \n  lVar2 = FUN_002ecd20(param_3);\n  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));\n  bind_textdomain_codeset(*param_2,uVar3);\n  uVar3 = FUN_0031be80();\n  FUN_002dca70(local_30,param_3);\n                    \n  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);\n  FUN_002dd1b0(local_30);\n  return uVar1;\n}" ({ "{") (declaration "undefined4 uVar1;" (type_identifier "undefined4") (identifier "uVar1") (; ";")) (declaration "long lVar2;" (sized_type_specifier "long" (long "long")) (identifier "lVar2") (; ";")) (declaration "undefined8 uVar3;" (type_identifier "undefined8") (identifier "uVar3") (; ";")) (declaration "undefined1 local_30 [16];" (type_identifier "undefined1") (array_declarator "local_30 [16]" (identifier "local_30") ([ "[") (number_literal "16") (] "]")) (; ";")) (expression_statement "lVar2 = FUN_002ecd20(param_3);" (assignment_expression "lVar2 = FUN_002ecd20(param_3)" (identifier "lVar2") (= "=") (call_expression "FUN_002ecd20(param_3)" (identifier "FUN_002ecd20") (argument_list "(param_3)" (( "(") (identifier "param_3") () ")")))) (; ";")) (expression_statement "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));" (assignment_expression "uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" (identifier "uVar3") (= "=") (call_expression "__nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10))" (identifier "__nl_langinfo_l") (argument_list "(0xe,*(undefined8 *)(lVar2 + 0x10))" (( "(") (number_literal "0xe") (, ",") (pointer_expression "*(undefined8 *)(lVar2 + 0x10)" (* "*") (cast_expression "(undefined8 *)(lVar2 + 0x10)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(lVar2 + 0x10)" (( "(") (binary_expression "lVar2 + 0x10" (identifier "lVar2") (+ "+") (number_literal "0x10")) () ")")))) () ")")))) (; ";")) (expression_statement "bind_textdomain_codeset(*param_2,uVar3);" (call_expression "bind_textdomain_codeset(*param_2,uVar3)" (identifier "bind_textdomain_codeset") (argument_list "(*param_2,uVar3)" (( "(") (pointer_expression "*param_2" (* "*") (identifier "param_2")) (, ",") (identifier "uVar3") () ")"))) (; ";")) (expression_statement "uVar3 = FUN_0031be80();" (assignment_expression "uVar3 = FUN_0031be80()" (identifier "uVar3") (= "=") (call_expression "FUN_0031be80()" (identifier "FUN_0031be80") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "FUN_002dca70(local_30,param_3);" (call_expression "FUN_002dca70(local_30,param_3)" (identifier "FUN_002dca70") (argument_list "(local_30,param_3)" (( "(") (identifier "local_30") (, ",") (identifier "param_3") () ")"))) (; ";")) (expression_statement "uVar1 = FUN_0031c090(uVar3,*param_2,local_30);" (assignment_expression "uVar1 = FUN_0031c090(uVar3,*param_2,local_30)" (identifier "uVar1") (= "=") (call_expression "FUN_0031c090(uVar3,*param_2,local_30)" (identifier "FUN_0031c090") (argument_list "(uVar3,*param_2,local_30)" (( "(") (identifier "uVar3") (, ",") (pointer_expression "*param_2" (* "*") (identifier "param_2")) (, ",") (identifier "local_30") () ")")))) (; ";")) (expression_statement "FUN_002dd1b0(local_30);" (call_expression "FUN_002dd1b0(local_30)" (identifier "FUN_002dd1b0") (argument_list "(local_30)" (( "(") (identifier "local_30") () ")"))) (; ";")) (return_statement "return uVar1;" (return "return") (identifier "uVar1") (; ";")) (} "}")))

/* std::messages<char>::do_open(std::string const&, std::locale const&) const */

type_1 __thiscall
var_2::type_2<char>::function_1(type_2<char> *this,type_3 *param_1,type_4 *param_2)

{
  type_1 uVar1;
  type_5 *var_6;
  type_6 uVar3;
  type_7 *pCVar4;
  type_4 local_30 [16];
  
  var_6 = var_1<var_2::type_5<var_3,var_3,var_4>>(param_2);
  uVar3 = var_5(0xe,*(type_6 *)(var_6 + 0x10));
  var_7(*(type_6 *)param_1,uVar3);
  pCVar4 = (type_7 *)var_8();
  locale::type_4(local_30,param_2);
                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */
  uVar1 = type_7::var_9(pCVar4,*(type_6 *)param_1,local_30);
  locale::~type_4(local_30);
  return uVar1;
}


(translation_unit (function_definition type: (type_identifier) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (number_literal) (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))))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (return_statement (identifier)))))

undefined4 MASKED(undefined8 param_1,undefined8 *param_2,undefined8 param_3)

{
  undefined4 uVar1;
  long lVar2;
  undefined8 uVar3;
  undefined1 local_30 [16];
  
  lVar2 = FUN_002ecd20(param_3);
  uVar3 = __nl_langinfo_l(0xe,*(undefined8 *)(lVar2 + 0x10));
  bind_textdomain_codeset(*param_2,uVar3);
  uVar3 = FUN_0031be80();
  FUN_002dca70(local_30,param_3);
                    /* try { // try from 00365444 to 00365448 has its CatchHandler @ 00365460 */
  uVar1 = FUN_0031c090(uVar3,*param_2,local_30);
  FUN_002dd1b0(local_30);
  return uVar1;
}

