
/* std::collate<char>::do_hash(char const*, char const*) const */

uint __thiscall std::collate<char>::do_hash(collate<char> *this,char *param_1,char *param_2)

{
  char cVar1;
  uint uVar2;
  
  uVar2 = 0;
  if (param_1 < param_2) {
    do {
      cVar1 = *param_1;
      param_1 = param_1 + 1;
      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;
    } while (param_2 != param_1);
  }
  return uVar2;
}



uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)

{
  char cVar1;
  uint uVar2;
  
  uVar2 = 0;
  if (param_2 < param_3) {
    do {
      cVar1 = *param_2;
      param_2 = param_2 + 1;
      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;
    } while (param_3 != param_2);
  }
  return uVar2;
}


PUSH EBX
MOV EDX,dword ptr [ESP + 0xc]
XOR EAX,EAX
MOV EBX,dword ptr [ESP + 0x10]
CMP EDX,EBX
JNC 0x00259def
NOP
MOVSX ECX,byte ptr [EDX]
ROL EAX,0x7
ADD EDX,0x1
ADD EAX,ECX
CMP EBX,EDX
JNZ 0x00259de0
POP EBX
RET
(translation_unit "uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}\n\n" (function_definition "uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)" identifier (parameter_list "(undefined4 param_1,char *param_2,char *param_3)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" identifier = number_literal) ;) (if_statement "if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" if (parenthesized_expression "(param_2 < param_3)" ( (binary_expression "param_2 < param_3" identifier < identifier) )) (compound_statement "{\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" { (do_statement "do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);" do (compound_statement "{\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    }" { (expression_statement "cVar1 = *param_2;" (assignment_expression "cVar1 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (expression_statement "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;" (assignment_expression "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" identifier = (binary_expression "(uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" (parenthesized_expression "(uVar2 << 7 | uVar2 >> 0x19)" ( (binary_expression "uVar2 << 7 | uVar2 >> 0x19" (binary_expression "uVar2 << 7" identifier << number_literal) | (binary_expression "uVar2 >> 0x19" identifier >> number_literal)) )) + (cast_expression "(int)cVar1" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }) while (parenthesized_expression "(param_3 != param_2)" ( (binary_expression "param_3 != param_2" identifier != identifier) )) ;) })) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "/* std::collate<char>::do_hash(char const*, char const*) const */\n\nuint __thiscall std::collate<char>::do_hash(collate<char> *this,char *param_1,char *param_2)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_1 < param_2) {\n    do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);\n  }\n  return uVar2;\n}\n\n" comment (function_definition "uint __thiscall std::collate<char>::do_hash(collate<char> *this,char *param_1,char *param_2)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_1 < param_2) {\n    do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);\n  }\n  return uVar2;\n}" type_identifier (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::collate<char>::" identifier : : identifier < primitive_type > : :) (function_declarator "do_hash(collate<char> *this,char *param_1,char *param_2)" identifier (parameter_list "(collate<char> *this,char *param_1,char *param_2)" ( (parameter_declaration "collate<char> *this" type_identifier (ERROR "<char>" < primitive_type >) (pointer_declarator "*this" * identifier)) , (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_1 < param_2) {\n    do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);\n  }\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" identifier = number_literal) ;) (if_statement "if (param_1 < param_2) {\n    do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);\n  }" if (parenthesized_expression "(param_1 < param_2)" ( (binary_expression "param_1 < param_2" identifier < identifier) )) (compound_statement "{\n    do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);\n  }" { (do_statement "do {\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_2 != param_1);" do (compound_statement "{\n      cVar1 = *param_1;\n      param_1 = param_1 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    }" { (expression_statement "cVar1 = *param_1;" (assignment_expression "cVar1 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;" (assignment_expression "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" identifier = (binary_expression "(uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" (parenthesized_expression "(uVar2 << 7 | uVar2 >> 0x19)" ( (binary_expression "uVar2 << 7 | uVar2 >> 0x19" (binary_expression "uVar2 << 7" identifier << number_literal) | (binary_expression "uVar2 >> 0x19" identifier >> number_literal)) )) + (cast_expression "(int)cVar1" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }) while (parenthesized_expression "(param_2 != param_1)" ( (binary_expression "param_2 != param_1" identifier != identifier) )) ;) })) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}\n\n" (function_definition "uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)" identifier (parameter_list "(undefined4 param_1,char *param_2,char *param_3)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" identifier = number_literal) ;) (if_statement "if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" if (parenthesized_expression "(param_2 < param_3)" ( (binary_expression "param_2 < param_3" identifier < identifier) )) (compound_statement "{\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" { (do_statement "do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);" do (compound_statement "{\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    }" { (expression_statement "cVar1 = *param_2;" (assignment_expression "cVar1 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (expression_statement "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;" (assignment_expression "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" identifier = (binary_expression "(uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" (parenthesized_expression "(uVar2 << 7 | uVar2 >> 0x19)" ( (binary_expression "uVar2 << 7 | uVar2 >> 0x19" (binary_expression "uVar2 << 7" identifier << number_literal) | (binary_expression "uVar2 >> 0x19" identifier >> number_literal)) )) + (cast_expression "(int)cVar1" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }) while (parenthesized_expression "(param_3 != param_2)" ( (binary_expression "param_3 != param_2" 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 (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression (parenthesized_expression ( (binary_expression (binary_expression IDENT << LIT) | (binary_expression IDENT >> LIT)) )) + (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) }) while (parenthesized_expression ( (binary_expression IDENT != IDENT) )) ;) })) (return_statement return IDENT ;) })))
(function_definition "uint FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)\n\n{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" (type_identifier "uint") (function_declarator "FUN_00259dd0(undefined4 param_1,char *param_2,char *param_3)" (identifier "FUN_00259dd0") (parameter_list "(undefined4 param_1,char *param_2,char *param_3)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) (, ",") (parameter_declaration "char *param_2" (primitive_type "char") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "char *param_3" (primitive_type "char") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) () ")"))) (compound_statement "{\n  char cVar1;\n  uint uVar2;\n  \n  uVar2 = 0;\n  if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }\n  return uVar2;\n}" ({ "{") (declaration "char cVar1;" (primitive_type "char") (identifier "cVar1") (; ";")) (declaration "uint uVar2;" (type_identifier "uint") (identifier "uVar2") (; ";")) (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" (identifier "uVar2") (= "=") (number_literal "0")) (; ";")) (if_statement "if (param_2 < param_3) {\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" (if "if") (parenthesized_expression "(param_2 < param_3)" (( "(") (binary_expression "param_2 < param_3" (identifier "param_2") (< "<") (identifier "param_3")) () ")")) (compound_statement "{\n    do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);\n  }" ({ "{") (do_statement "do {\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    } while (param_3 != param_2);" (do "do") (compound_statement "{\n      cVar1 = *param_2;\n      param_2 = param_2 + 1;\n      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;\n    }" ({ "{") (expression_statement "cVar1 = *param_2;" (assignment_expression "cVar1 = *param_2" (identifier "cVar1") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" (identifier "param_2") (= "=") (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;" (assignment_expression "uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" (identifier "uVar2") (= "=") (binary_expression "(uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1" (parenthesized_expression "(uVar2 << 7 | uVar2 >> 0x19)" (( "(") (binary_expression "uVar2 << 7 | uVar2 >> 0x19" (binary_expression "uVar2 << 7" (identifier "uVar2") (<< "<<") (number_literal "7")) (| "|") (binary_expression "uVar2 >> 0x19" (identifier "uVar2") (>> ">>") (number_literal "0x19"))) () ")")) (+ "+") (cast_expression "(int)cVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "cVar1")))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_3 != param_2)" (( "(") (binary_expression "param_3 != param_2" (identifier "param_3") (!= "!=") (identifier "param_2")) () ")")) (; ";")) (} "}"))) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

/* std::collate<char>::do_hash(char const*, char const*) const */

type_1 __thiscall std::type_2<char>::function_1(type_2<char> *this,char *var_1,char *var_2)

{
  char cVar1;
  type_1 var_3;
  
  var_3 = 0;
  if (var_1 < var_2) {
    do {
      cVar1 = *var_1;
      var_1 = var_1 + 1;
      var_3 = (var_3 << 7 | var_3 >> 0x19) + (int)cVar1;
    } while (var_2 != var_1);
  }
  return var_3;
}


(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: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (do_statement body: (compound_statement (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)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))))) (return_statement (identifier)))))

uint MASKED(undefined4 param_1,char *param_2,char *param_3)

{
  char cVar1;
  uint uVar2;
  
  uVar2 = 0;
  if (param_2 < param_3) {
    do {
      cVar1 = *param_2;
      param_2 = param_2 + 1;
      uVar2 = (uVar2 << 7 | uVar2 >> 0x19) + (int)cVar1;
    } while (param_3 != param_2);
  }
  return uVar2;
}

