
demangle_component * __regparm3 d_ref_qualifier(d_info *di,demangle_component *sub)

{
  char cVar1;
  demangle_component *pdVar2;
  demangle_component *ret;
  demangle_component_type type;
  int iVar3;
  
  cVar1 = *di->n;
  if ((cVar1 != 'R') && (cVar1 != 'O')) {
    return sub;
  }
  type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS;
  iVar3 = di->expansion + 3;
  if (cVar1 == 'R') {
    iVar3 = di->expansion + 2;
    type = DEMANGLE_COMPONENT_REFERENCE_THIS;
  }
  di->expansion = iVar3;
  di->n = di->n + 1;
  pdVar2 = d_make_comp(di,type,sub,(demangle_component *)0x0);
  return pdVar2;
}



undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)

{
  char cVar1;
  undefined4 uVar2;
  int iVar3;
  
  cVar1 = **(char **)(param_1 + 0xc);
  if ((cVar1 != 'R') && (cVar1 != 'O')) {
    return param_2;
  }
  iVar3 = *(int *)(param_1 + 0x2c) + 3;
  if (cVar1 == 'R') {
    iVar3 = *(int *)(param_1 + 0x2c) + 2;
  }
  *(int *)(param_1 + 0x2c) = iVar3;
  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;
  uVar2 = FUN_001ea760(0);
  return uVar2;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
MOV EBX,dword ptr [EAX + 0xc]
MOVZX ECX,byte ptr [EBX]
CMP CL,0x52
JZ 0x001ea7f0
CMP CL,0x4f
JZ 0x001ea7f0
POP EBX
MOV EAX,EDX
POP ESI
POP EDI
POP EBP
RET
MOV EBP,dword ptr [EAX + 0x2c]
MOV ESI,0x20
LEA EDI,[EBP + 0x3]
CMP CL,0x52
JNZ 0x001ea808
LEA EDI,[EBP + 0x2]
MOV ESI,0x1f
ADD EBX,0x1
MOV dword ptr [EAX + 0x2c],EDI
MOV ECX,EDX
MOV EDX,ESI
MOV dword ptr [EAX + 0xc],EBX
PUSH 0x0
CALL 0x001ea760
MOV EDX,EAX
POP EAX
POP EBX
MOV EAX,EDX
POP ESI
POP EDI
POP EBP
RET
(translation_unit "undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}\n\n" (function_definition "undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_001ea7d0(int param_1,undefined4 param_2)" identifier (parameter_list "(int param_1,undefined4 param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) ))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (expression_statement "cVar1 = **(char **)(param_1 + 0xc);" (assignment_expression "cVar1 = **(char **)(param_1 + 0xc)" identifier = (pointer_expression "**(char **)(param_1 + 0xc)" * (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))))) ;) (if_statement "if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }" if (parenthesized_expression "((cVar1 != 'R') && (cVar1 != 'O'))" ( (binary_expression "(cVar1 != 'R') && (cVar1 != 'O')" (parenthesized_expression "(cVar1 != 'R')" ( (binary_expression "cVar1 != 'R'" identifier != (char_literal "'R'" ' character ')) )) && (parenthesized_expression "(cVar1 != 'O')" ( (binary_expression "cVar1 != 'O'" identifier != (char_literal "'O'" ' character ')) ))) )) (compound_statement "{\n    return param_2;\n  }" { (return_statement "return param_2;" return identifier ;) })) (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 3;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 3" identifier = (binary_expression "*(int *)(param_1 + 0x2c) + 3" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) + number_literal)) ;) (if_statement "if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" if (parenthesized_expression "(cVar1 == 'R')" ( (binary_expression "cVar1 == 'R'" identifier == (char_literal "'R'" ' character ')) )) (compound_statement "{\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" { (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 2;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 2" identifier = (binary_expression "*(int *)(param_1 + 0x2c) + 2" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) + number_literal)) ;) })) (expression_statement "*(int *)(param_1 + 0x2c) = iVar3;" (assignment_expression "*(int *)(param_1 + 0x2c) = iVar3" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;" (assignment_expression "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = (binary_expression "*(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) + number_literal)) ;) (expression_statement "uVar2 = FUN_001ea760(0);" (assignment_expression "uVar2 = FUN_001ea760(0)" identifier = (call_expression "FUN_001ea760(0)" identifier (argument_list "(0)" ( number_literal )))) ;) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "demangle_component * __regparm3 d_ref_qualifier(d_info *di,demangle_component *sub)\n\n{\n  char cVar1;\n  demangle_component *pdVar2;\n  demangle_component *ret;\n  demangle_component_type type;\n  int iVar3;\n  \n  cVar1 = *di->n;\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return sub;\n  }\n  type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS;\n  iVar3 = di->expansion + 3;\n  if (cVar1 == 'R') {\n    iVar3 = di->expansion + 2;\n    type = DEMANGLE_COMPONENT_REFERENCE_THIS;\n  }\n  di->expansion = iVar3;\n  di->n = di->n + 1;\n  pdVar2 = d_make_comp(di,type,sub,(demangle_component *)0x0);\n  return pdVar2;\n}\n\n" (ERROR "demangle_component * __regparm3 d_ref_qualifier(d_info *di,demangle_component *sub)" (binary_expression "demangle_component * __regparm3 d_ref_qualifier(d_info *di,demangle_component *sub)" identifier * (ERROR "__regparm3" identifier) (call_expression "d_ref_qualifier(d_info *di,demangle_component *sub)" identifier (argument_list "(d_info *di,demangle_component *sub)" ( (binary_expression "d_info *di" identifier * identifier) , (binary_expression "demangle_component *sub" identifier * identifier) ))))) (compound_statement "{\n  char cVar1;\n  demangle_component *pdVar2;\n  demangle_component *ret;\n  demangle_component_type type;\n  int iVar3;\n  \n  cVar1 = *di->n;\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return sub;\n  }\n  type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS;\n  iVar3 = di->expansion + 3;\n  if (cVar1 == 'R') {\n    iVar3 = di->expansion + 2;\n    type = DEMANGLE_COMPONENT_REFERENCE_THIS;\n  }\n  di->expansion = iVar3;\n  di->n = di->n + 1;\n  pdVar2 = d_make_comp(di,type,sub,(demangle_component *)0x0);\n  return pdVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "demangle_component *pdVar2;" type_identifier (pointer_declarator "*pdVar2" * identifier) ;) (declaration "demangle_component *ret;" type_identifier (pointer_declarator "*ret" * identifier) ;) (declaration "demangle_component_type type;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (expression_statement "cVar1 = *di->n;" (assignment_expression "cVar1 = *di->n" identifier = (pointer_expression "*di->n" * (field_expression "di->n" identifier -> field_identifier))) ;) (if_statement "if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return sub;\n  }" if (parenthesized_expression "((cVar1 != 'R') && (cVar1 != 'O'))" ( (binary_expression "(cVar1 != 'R') && (cVar1 != 'O')" (parenthesized_expression "(cVar1 != 'R')" ( (binary_expression "cVar1 != 'R'" identifier != (char_literal "'R'" ' character ')) )) && (parenthesized_expression "(cVar1 != 'O')" ( (binary_expression "cVar1 != 'O'" identifier != (char_literal "'O'" ' character ')) ))) )) (compound_statement "{\n    return sub;\n  }" { (return_statement "return sub;" return identifier ;) })) (expression_statement "type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS;" (assignment_expression "type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS" identifier = identifier) ;) (expression_statement "iVar3 = di->expansion + 3;" (assignment_expression "iVar3 = di->expansion + 3" identifier = (binary_expression "di->expansion + 3" (field_expression "di->expansion" identifier -> field_identifier) + number_literal)) ;) (if_statement "if (cVar1 == 'R') {\n    iVar3 = di->expansion + 2;\n    type = DEMANGLE_COMPONENT_REFERENCE_THIS;\n  }" if (parenthesized_expression "(cVar1 == 'R')" ( (binary_expression "cVar1 == 'R'" identifier == (char_literal "'R'" ' character ')) )) (compound_statement "{\n    iVar3 = di->expansion + 2;\n    type = DEMANGLE_COMPONENT_REFERENCE_THIS;\n  }" { (expression_statement "iVar3 = di->expansion + 2;" (assignment_expression "iVar3 = di->expansion + 2" identifier = (binary_expression "di->expansion + 2" (field_expression "di->expansion" identifier -> field_identifier) + number_literal)) ;) (expression_statement "type = DEMANGLE_COMPONENT_REFERENCE_THIS;" (assignment_expression "type = DEMANGLE_COMPONENT_REFERENCE_THIS" identifier = identifier) ;) })) (expression_statement "di->expansion = iVar3;" (assignment_expression "di->expansion = iVar3" (field_expression "di->expansion" identifier -> field_identifier) = identifier) ;) (expression_statement "di->n = di->n + 1;" (assignment_expression "di->n = di->n + 1" (field_expression "di->n" identifier -> field_identifier) = (binary_expression "di->n + 1" (field_expression "di->n" identifier -> field_identifier) + number_literal)) ;) (expression_statement "pdVar2 = d_make_comp(di,type,sub,(demangle_component *)0x0);" (assignment_expression "pdVar2 = d_make_comp(di,type,sub,(demangle_component *)0x0)" identifier = (call_expression "d_make_comp(di,type,sub,(demangle_component *)0x0)" identifier (argument_list "(di,type,sub,(demangle_component *)0x0)" ( identifier , identifier , identifier , (cast_expression "(demangle_component *)0x0" ( (type_descriptor "demangle_component *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) )))) ;) (return_statement "return pdVar2;" return identifier ;) }))
(translation_unit "undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}\n\n" (function_definition "undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_001ea7d0(int param_1,undefined4 param_2)" identifier (parameter_list "(int param_1,undefined4 param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) ))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (expression_statement "cVar1 = **(char **)(param_1 + 0xc);" (assignment_expression "cVar1 = **(char **)(param_1 + 0xc)" identifier = (pointer_expression "**(char **)(param_1 + 0xc)" * (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))))) ;) (if_statement "if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }" if (parenthesized_expression "((cVar1 != 'R') && (cVar1 != 'O'))" ( (binary_expression "(cVar1 != 'R') && (cVar1 != 'O')" (parenthesized_expression "(cVar1 != 'R')" ( (binary_expression "cVar1 != 'R'" identifier != (char_literal "'R'" ' character ')) )) && (parenthesized_expression "(cVar1 != 'O')" ( (binary_expression "cVar1 != 'O'" identifier != (char_literal "'O'" ' character ')) ))) )) (compound_statement "{\n    return param_2;\n  }" { (return_statement "return param_2;" return identifier ;) })) (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 3;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 3" identifier = (binary_expression "*(int *)(param_1 + 0x2c) + 3" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) + number_literal)) ;) (if_statement "if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" if (parenthesized_expression "(cVar1 == 'R')" ( (binary_expression "cVar1 == 'R'" identifier == (char_literal "'R'" ' character ')) )) (compound_statement "{\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" { (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 2;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 2" identifier = (binary_expression "*(int *)(param_1 + 0x2c) + 2" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) + number_literal)) ;) })) (expression_statement "*(int *)(param_1 + 0x2c) = iVar3;" (assignment_expression "*(int *)(param_1 + 0x2c) = iVar3" (pointer_expression "*(int *)(param_1 + 0x2c)" * (cast_expression "(int *)(param_1 + 0x2c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x2c)" ( (binary_expression "param_1 + 0x2c" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;" (assignment_expression "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = (binary_expression "*(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" * (cast_expression "(char **)(param_1 + 0xc)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) + number_literal)) ;) (expression_statement "uVar2 = FUN_001ea760(0);" (assignment_expression "uVar2 = FUN_001ea760(0)" identifier = (call_expression "FUN_001ea760(0)" identifier (argument_list "(0)" ( number_literal )))) ;) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (char_literal ' character ')) )) && (parenthesized_expression ( (binary_expression IDENT != (char_literal ' character ')) ))) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT)) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT )))) ;) (return_statement return IDENT ;) })))
(function_definition "undefined4 __regparm3 FUN_001ea7d0(int param_1,undefined4 param_2)\n\n{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" (type_identifier "undefined4") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_001ea7d0(int param_1,undefined4 param_2)" (identifier "FUN_001ea7d0") (parameter_list "(int param_1,undefined4 param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) () ")"))) (compound_statement "{\n  char cVar1;\n  undefined4 uVar2;\n  int iVar3;\n  \n  cVar1 = **(char **)(param_1 + 0xc);\n  if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }\n  iVar3 = *(int *)(param_1 + 0x2c) + 3;\n  if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }\n  *(int *)(param_1 + 0x2c) = iVar3;\n  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;\n  uVar2 = FUN_001ea760(0);\n  return uVar2;\n}" ({ "{") (declaration "char cVar1;" (primitive_type "char") (identifier "cVar1") (; ";")) (declaration "undefined4 uVar2;" (type_identifier "undefined4") (identifier "uVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (expression_statement "cVar1 = **(char **)(param_1 + 0xc);" (assignment_expression "cVar1 = **(char **)(param_1 + 0xc)" (identifier "cVar1") (= "=") (pointer_expression "**(char **)(param_1 + 0xc)" (* "*") (pointer_expression "*(char **)(param_1 + 0xc)" (* "*") (cast_expression "(char **)(param_1 + 0xc)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))))) (; ";")) (if_statement "if ((cVar1 != 'R') && (cVar1 != 'O')) {\n    return param_2;\n  }" (if "if") (parenthesized_expression "((cVar1 != 'R') && (cVar1 != 'O'))" (( "(") (binary_expression "(cVar1 != 'R') && (cVar1 != 'O')" (parenthesized_expression "(cVar1 != 'R')" (( "(") (binary_expression "cVar1 != 'R'" (identifier "cVar1") (!= "!=") (char_literal "'R'" (' "'") (character "R") (' "'"))) () ")")) (&& "&&") (parenthesized_expression "(cVar1 != 'O')" (( "(") (binary_expression "cVar1 != 'O'" (identifier "cVar1") (!= "!=") (char_literal "'O'" (' "'") (character "O") (' "'"))) () ")"))) () ")")) (compound_statement "{\n    return param_2;\n  }" ({ "{") (return_statement "return param_2;" (return "return") (identifier "param_2") (; ";")) (} "}"))) (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 3;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 3" (identifier "iVar3") (= "=") (binary_expression "*(int *)(param_1 + 0x2c) + 3" (pointer_expression "*(int *)(param_1 + 0x2c)" (* "*") (cast_expression "(int *)(param_1 + 0x2c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x2c)" (( "(") (binary_expression "param_1 + 0x2c" (identifier "param_1") (+ "+") (number_literal "0x2c")) () ")")))) (+ "+") (number_literal "3"))) (; ";")) (if_statement "if (cVar1 == 'R') {\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" (if "if") (parenthesized_expression "(cVar1 == 'R')" (( "(") (binary_expression "cVar1 == 'R'" (identifier "cVar1") (== "==") (char_literal "'R'" (' "'") (character "R") (' "'"))) () ")")) (compound_statement "{\n    iVar3 = *(int *)(param_1 + 0x2c) + 2;\n  }" ({ "{") (expression_statement "iVar3 = *(int *)(param_1 + 0x2c) + 2;" (assignment_expression "iVar3 = *(int *)(param_1 + 0x2c) + 2" (identifier "iVar3") (= "=") (binary_expression "*(int *)(param_1 + 0x2c) + 2" (pointer_expression "*(int *)(param_1 + 0x2c)" (* "*") (cast_expression "(int *)(param_1 + 0x2c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x2c)" (( "(") (binary_expression "param_1 + 0x2c" (identifier "param_1") (+ "+") (number_literal "0x2c")) () ")")))) (+ "+") (number_literal "2"))) (; ";")) (} "}"))) (expression_statement "*(int *)(param_1 + 0x2c) = iVar3;" (assignment_expression "*(int *)(param_1 + 0x2c) = iVar3" (pointer_expression "*(int *)(param_1 + 0x2c)" (* "*") (cast_expression "(int *)(param_1 + 0x2c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x2c)" (( "(") (binary_expression "param_1 + 0x2c" (identifier "param_1") (+ "+") (number_literal "0x2c")) () ")")))) (= "=") (identifier "iVar3")) (; ";")) (expression_statement "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;" (assignment_expression "*(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" (* "*") (cast_expression "(char **)(param_1 + 0xc)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (= "=") (binary_expression "*(char **)(param_1 + 0xc) + 1" (pointer_expression "*(char **)(param_1 + 0xc)" (* "*") (cast_expression "(char **)(param_1 + 0xc)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar2 = FUN_001ea760(0);" (assignment_expression "uVar2 = FUN_001ea760(0)" (identifier "uVar2") (= "=") (call_expression "FUN_001ea760(0)" (identifier "FUN_001ea760") (argument_list "(0)" (( "(") (number_literal "0") () ")")))) (; ";")) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

type_1 * __regparm3 d_ref_qualifier(d_info *di,type_1 *sub)

{
  char var_1;
  type_1 *pdVar2;
  type_1 *ret;
  type_2 type;
  int iVar3;
  
  var_1 = *di->n;
  if ((var_1 != 'R') && (var_1 != 'O')) {
    return sub;
  }
  type = DEMANGLE_COMPONENT_RVALUE_REFERENCE_THIS;
  iVar3 = di->expansion + 3;
  if (var_1 == 'R') {
    iVar3 = di->expansion + 2;
    type = DEMANGLE_COMPONENT_REFERENCE_THIS;
  }
  di->expansion = iVar3;
  di->n = di->n + 1;
  pdVar2 = var_2(di,type,sub,(type_1 *)0x0);
  return pdVar2;
}


(translation_unit (function_definition type: (type_identifier) (ERROR (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (number_literal))))) (return_statement (identifier)))))

undefined4 __regparm3 MASKED(int param_1,undefined4 param_2)

{
  char cVar1;
  undefined4 uVar2;
  int iVar3;
  
  cVar1 = **(char **)(param_1 + 0xc);
  if ((cVar1 != 'R') && (cVar1 != 'O')) {
    return param_2;
  }
  iVar3 = *(int *)(param_1 + 0x2c) + 3;
  if (cVar1 == 'R') {
    iVar3 = *(int *)(param_1 + 0x2c) + 2;
  }
  *(int *)(param_1 + 0x2c) = iVar3;
  *(char **)(param_1 + 0xc) = *(char **)(param_1 + 0xc) + 1;
  uVar2 = FUN_001ea760(0);
  return uVar2;
}

