
/* std::(anonymous namespace)::write_utf8_code_point(std::(anonymous namespace)::range<char, true>&,
   char32_t) */

undefined8 std::(anonymous_namespace)::write_utf8_code_point(range *param_1,wchar32 param_2)

{
  byte *pbVar1;
  char *pcVar2;
  
  if ((uint)param_2 < 0x80) {
    pbVar1 = *(byte **)param_1;
    if (pbVar1 == *(byte **)(param_1 + 8)) {
      return 0;
    }
    *(byte **)param_1 = pbVar1 + 1;
    *pbVar1 = (byte)param_2;
    return 1;
  }
  if ((uint)param_2 < 0x800) {
    pcVar2 = *(char **)param_1;
    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {
      return 0;
    }
    *(char **)param_1 = pcVar2 + 1;
    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;
  }
  else {
    if ((uint)param_2 < 0x10000) {
      pcVar2 = *(char **)param_1;
      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {
        return 0;
      }
      *(char **)param_1 = pcVar2 + 1;
      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;
    }
    else {
      if (0x10ffff < (uint)param_2) {
        return 0;
      }
      pcVar2 = *(char **)param_1;
      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {
        return 0;
      }
      *(char **)param_1 = pcVar2 + 1;
      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;
      pcVar2 = *(char **)param_1;
      *(char **)param_1 = pcVar2 + 1;
      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;
    }
    pcVar2 = *(char **)param_1;
    *(char **)param_1 = pcVar2 + 1;
    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;
  }
  pcVar2 = *(char **)param_1;
  *(char **)param_1 = pcVar2 + 1;
  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;
  return 1;
}



undefined8 FUN_003b7390(long *param_1,uint param_2)

{
  byte *pbVar1;
  char *pcVar2;
  
  if (param_2 < 0x80) {
    pbVar1 = (byte *)*param_1;
    if (pbVar1 == (byte *)param_1[1]) {
      return 0;
    }
    *param_1 = (long)(pbVar1 + 1);
    *pbVar1 = (byte)param_2;
    return 1;
  }
  if (param_2 < 0x800) {
    pcVar2 = (char *)*param_1;
    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {
      return 0;
    }
    *param_1 = (long)(pcVar2 + 1);
    *pcVar2 = (char)(param_2 >> 6) + -0x40;
  }
  else {
    if (param_2 < 0x10000) {
      pcVar2 = (char *)*param_1;
      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {
        return 0;
      }
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;
    }
    else {
      if (0x10ffff < param_2) {
        return 0;
      }
      pcVar2 = (char *)*param_1;
      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {
        return 0;
      }
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;
      pcVar2 = (char *)*param_1;
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;
    }
    pcVar2 = (char *)*param_1;
    *param_1 = (long)(pcVar2 + 1);
    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;
  }
  pcVar2 = (char *)*param_1;
  *param_1 = (long)(pcVar2 + 1);
  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;
  return 1;
}


CMP ESI,0x7f
JA 0x003b73b0
MOV RAX,qword ptr [RDI]
CMP RAX,qword ptr [RDI + 0x8]
JZ 0x003b73f8
LEA RDX,[RAX + 0x1]
MOV qword ptr [RDI],RDX
MOV byte ptr [RAX],SIL
MOV EAX,0x1
RET
CMP ESI,0x7ff
JA 0x003b7400
MOV RCX,qword ptr [RDI]
MOV RDX,qword ptr [RDI + 0x8]
XOR EAX,EAX
SUB RDX,RCX
CMP RDX,0x1
JBE 0x003b73fa
LEA RAX,[RCX + 0x1]
MOV qword ptr [RDI],RAX
MOV EAX,ESI
SHR EAX,0x6
SUB EAX,0x40
MOV byte ptr [RCX],AL
MOV RAX,qword ptr [RDI]
AND ESI,0x3f
ADD ESI,-0x80
LEA RDX,[RAX + 0x1]
MOV qword ptr [RDI],RDX
MOV byte ptr [RAX],SIL
MOV EAX,0x1
RET
XOR EAX,EAX
RET
CMP ESI,0xffff
JBE 0x003b7470
XOR EAX,EAX
CMP ESI,0x10ffff
JA 0x003b73fa
MOV RCX,qword ptr [RDI]
MOV RDX,qword ptr [RDI + 0x8]
SUB RDX,RCX
CMP RDX,0x3
JBE 0x003b73fa
LEA RAX,[RCX + 0x1]
MOV qword ptr [RDI],RAX
MOV EAX,ESI
SHR EAX,0x12
SUB EAX,0x10
MOV byte ptr [RCX],AL
MOV RDX,qword ptr [RDI]
LEA RAX,[RDX + 0x1]
MOV qword ptr [RDI],RAX
MOV EAX,ESI
SHR EAX,0xc
AND EAX,0x3f
ADD EAX,-0x80
MOV byte ptr [RDX],AL
MOV RDX,qword ptr [RDI]
LEA RAX,[RDX + 0x1]
MOV qword ptr [RDI],RAX
MOV EAX,ESI
SHR EAX,0x6
AND EAX,0x3f
ADD EAX,-0x80
MOV byte ptr [RDX],AL
JMP 0x003b73db
MOV RCX,qword ptr [RDI]
MOV RDX,qword ptr [RDI + 0x8]
XOR EAX,EAX
SUB RDX,RCX
CMP RDX,0x2
JBE 0x003b73fa
LEA RAX,[RCX + 0x1]
MOV qword ptr [RDI],RAX
MOV EAX,ESI
SHR EAX,0xc
SUB EAX,0x20
MOV byte ptr [RCX],AL
JMP 0x003b744a
(translation_unit "undefined8 FUN_003b7390(long *param_1,uint param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}\n\n" (function_definition "undefined8 FUN_003b7390(long *param_1,uint param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" type_identifier (function_declarator "FUN_003b7390(long *param_1,uint param_2)" identifier (parameter_list "(long *param_1,uint param_2)" ( (parameter_declaration "long *param_1" (sized_type_specifier "long" long) (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" if (parenthesized_expression "(param_2 < 0x80)" ( (binary_expression "param_2 < 0x80" identifier < number_literal) )) (compound_statement "{\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" { (expression_statement "pbVar1 = (byte *)*param_1;" (assignment_expression "pbVar1 = (byte *)*param_1" identifier = (cast_expression "(byte *)*param_1" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }" if (parenthesized_expression "(pbVar1 == (byte *)param_1[1])" ( (binary_expression "pbVar1 == (byte *)param_1[1]" identifier == (cast_expression "(byte *)param_1[1]" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "param_1[1]" identifier [ number_literal ]))) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pbVar1 + 1);" (assignment_expression "*param_1 = (long)(pbVar1 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pbVar1 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pbVar1 + 1)" ( (binary_expression "pbVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "*pbVar1 = (byte)param_2;" (assignment_expression "*pbVar1 = (byte)param_2" (pointer_expression "*pbVar1" * identifier) = (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier)) ;) (return_statement "return 1;" return number_literal ;) })) (if_statement "if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" if (parenthesized_expression "(param_2 < 0x800)" ( (binary_expression "param_2 < 0x800" identifier < number_literal) )) (compound_statement "{\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }" { (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 2)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 2" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 6) + -0x40;" (assignment_expression "*pcVar2 = (char)(param_2 >> 6) + -0x40" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 6) + -0x40" (cast_expression "(char)(param_2 >> 6)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 6)" ( (binary_expression "param_2 >> 6" identifier >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" else (compound_statement "{\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" { (if_statement "if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" if (parenthesized_expression "(param_2 < 0x10000)" ( (binary_expression "param_2 < 0x10000" identifier < number_literal) )) (compound_statement "{\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }" { (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 3)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 3" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 0xc) + -0x20;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0xc) + -0x20" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 0xc) + -0x20" (cast_expression "(char)(param_2 >> 0xc)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 0xc)" ( (binary_expression "param_2 >> 0xc" identifier >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" else (compound_statement "{\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" { (if_statement "if (0x10ffff < param_2) {\n        return 0;\n      }" if (parenthesized_expression "(0x10ffff < param_2)" ( (binary_expression "0x10ffff < param_2" number_literal < identifier) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 4)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 4" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 0x12) + -0x10;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0x12) + -0x10" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 0x12) + -0x10" (cast_expression "(char)(param_2 >> 0x12)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 0x12)" ( (binary_expression "param_2 >> 0x12" identifier >> number_literal) ))) + number_literal)) ;) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 0xc) & 0x3f)" ( (binary_expression "(byte)(param_2 >> 0xc) & 0x3f" (call_expression "(byte)(param_2 >> 0xc)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(param_2 >> 0xc)" ( (binary_expression "param_2 >> 0xc" identifier >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)(param_2 >> 6) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 6) & 0x3f)" ( (binary_expression "(byte)(param_2 >> 6) & 0x3f" (call_expression "(byte)(param_2 >> 6)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(param_2 >> 6)" ( (binary_expression "param_2 >> 6" identifier >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)param_2 & 0x3f) + 0x80" (parenthesized_expression "((byte)param_2 & 0x3f)" ( (binary_expression "(byte)param_2 & 0x3f" (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier) & number_literal) )) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit "/* std::(anonymous namespace)::write_utf8_code_point(std::(anonymous namespace)::range<char, true>&,\n   char32_t) */\n\nundefined8 std::(anonymous_namespace)::write_utf8_code_point(range *param_1,wchar32 param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if ((uint)param_2 < 0x80) {\n    pbVar1 = *(byte **)param_1;\n    if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }\n    *(byte **)param_1 = pbVar1 + 1;\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if ((uint)param_2 < 0x800) {\n    pcVar2 = *(char **)param_1;\n    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;\n  }\n  else {\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = *(char **)param_1;\n  *(char **)param_1 = pcVar2 + 1;\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}\n\n" comment (function_definition "undefined8 std::(anonymous_namespace)::write_utf8_code_point(range *param_1,wchar32 param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if ((uint)param_2 < 0x80) {\n    pbVar1 = *(byte **)param_1;\n    if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }\n    *(byte **)param_1 = pbVar1 + 1;\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if ((uint)param_2 < 0x800) {\n    pcVar2 = *(char **)param_1;\n    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;\n  }\n  else {\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = *(char **)param_1;\n  *(char **)param_1 = pcVar2 + 1;\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" type_identifier (ERROR "std::(anonymous_namespace)::" identifier : : ( identifier ) : :) (function_declarator "write_utf8_code_point(range *param_1,wchar32 param_2)" identifier (parameter_list "(range *param_1,wchar32 param_2)" ( (parameter_declaration "range *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "wchar32 param_2" type_identifier identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if ((uint)param_2 < 0x80) {\n    pbVar1 = *(byte **)param_1;\n    if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }\n    *(byte **)param_1 = pbVar1 + 1;\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if ((uint)param_2 < 0x800) {\n    pcVar2 = *(char **)param_1;\n    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;\n  }\n  else {\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = *(char **)param_1;\n  *(char **)param_1 = pcVar2 + 1;\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if ((uint)param_2 < 0x80) {\n    pbVar1 = *(byte **)param_1;\n    if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }\n    *(byte **)param_1 = pbVar1 + 1;\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" if (parenthesized_expression "((uint)param_2 < 0x80)" ( (binary_expression "(uint)param_2 < 0x80" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) < number_literal) )) (compound_statement "{\n    pbVar1 = *(byte **)param_1;\n    if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }\n    *(byte **)param_1 = pbVar1 + 1;\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" { (expression_statement "pbVar1 = *(byte **)param_1;" (assignment_expression "pbVar1 = *(byte **)param_1" identifier = (pointer_expression "*(byte **)param_1" * (cast_expression "(byte **)param_1" ( (type_descriptor "byte **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (if_statement "if (pbVar1 == *(byte **)(param_1 + 8)) {\n      return 0;\n    }" if (parenthesized_expression "(pbVar1 == *(byte **)(param_1 + 8))" ( (binary_expression "pbVar1 == *(byte **)(param_1 + 8)" identifier == (pointer_expression "*(byte **)(param_1 + 8)" * (cast_expression "(byte **)(param_1 + 8)" ( (type_descriptor "byte **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) ))))) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(byte **)param_1 = pbVar1 + 1;" (assignment_expression "*(byte **)param_1 = pbVar1 + 1" (pointer_expression "*(byte **)param_1" * (cast_expression "(byte **)param_1" ( (type_descriptor "byte **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pbVar1 + 1" identifier + number_literal)) ;) (expression_statement "*pbVar1 = (byte)param_2;" (assignment_expression "*pbVar1 = (byte)param_2" (pointer_expression "*pbVar1" * identifier) = (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier)) ;) (return_statement "return 1;" return number_literal ;) })) (if_statement "if ((uint)param_2 < 0x800) {\n    pcVar2 = *(char **)param_1;\n    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;\n  }\n  else {\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }" if (parenthesized_expression "((uint)param_2 < 0x800)" ( (binary_expression "(uint)param_2 < 0x800" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) < number_literal) )) (compound_statement "{\n    pcVar2 = *(char **)param_1;\n    if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = (char)((uint)param_2 >> 6) + -0x40;\n  }" { (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (if_statement "if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2) {\n      return 0;\n    }" if (parenthesized_expression "((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2)" ( (binary_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 2" (call_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(*(long *)(param_1 + 8) - (long)pcVar2)" ( (binary_expression "*(long *)(param_1 + 8) - (long)pcVar2" (pointer_expression "*(long *)(param_1 + 8)" * (cast_expression "(long *)(param_1 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = (char)((uint)param_2 >> 6) + -0x40;" (assignment_expression "*pcVar2 = (char)((uint)param_2 >> 6) + -0x40" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)((uint)param_2 >> 6) + -0x40" (cast_expression "(char)((uint)param_2 >> 6)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "((uint)param_2 >> 6)" ( (binary_expression "(uint)param_2 >> 6" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }" else (compound_statement "{\n    if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = *(char **)param_1;\n    *(char **)param_1 = pcVar2 + 1;\n    *pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;\n  }" { (if_statement "if ((uint)param_2 < 0x10000) {\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }" if (parenthesized_expression "((uint)param_2 < 0x10000)" ( (binary_expression "(uint)param_2 < 0x10000" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) < number_literal) )) (compound_statement "{\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;\n    }" { (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (if_statement "if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3)" ( (binary_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 3" (call_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(*(long *)(param_1 + 8) - (long)pcVar2)" ( (binary_expression "*(long *)(param_1 + 8) - (long)pcVar2" (pointer_expression "*(long *)(param_1 + 8)" * (cast_expression "(long *)(param_1 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20;" (assignment_expression "*pcVar2 = (char)((uint)param_2 >> 0xc) + -0x20" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)((uint)param_2 >> 0xc) + -0x20" (cast_expression "(char)((uint)param_2 >> 0xc)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "((uint)param_2 >> 0xc)" ( (binary_expression "(uint)param_2 >> 0xc" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }" else (compound_statement "{\n      if (0x10ffff < (uint)param_2) {\n        return 0;\n      }\n      pcVar2 = *(char **)param_1;\n      if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;\n      pcVar2 = *(char **)param_1;\n      *(char **)param_1 = pcVar2 + 1;\n      *pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;\n    }" { (if_statement "if (0x10ffff < (uint)param_2) {\n        return 0;\n      }" if (parenthesized_expression "(0x10ffff < (uint)param_2)" ( (binary_expression "0x10ffff < (uint)param_2" number_literal < (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier)) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (if_statement "if ((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4)" ( (binary_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2) < 4" (call_expression "(ulong)(*(long *)(param_1 + 8) - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(*(long *)(param_1 + 8) - (long)pcVar2)" ( (binary_expression "*(long *)(param_1 + 8) - (long)pcVar2" (pointer_expression "*(long *)(param_1 + 8)" * (cast_expression "(long *)(param_1 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10;" (assignment_expression "*pcVar2 = (char)((uint)param_2 >> 0x12) + -0x10" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)((uint)param_2 >> 0x12) + -0x10" (cast_expression "(char)((uint)param_2 >> 0x12)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "((uint)param_2 >> 0x12)" ( (binary_expression "(uint)param_2 >> 0x12" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) >> number_literal) ))) + number_literal)) ;) (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)((uint)param_2 >> 0xc) & 0x3f) + 0x80" (parenthesized_expression "((byte)((uint)param_2 >> 0xc) & 0x3f)" ( (binary_expression "(byte)((uint)param_2 >> 0xc) & 0x3f" (call_expression "(byte)((uint)param_2 >> 0xc)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "((uint)param_2 >> 0xc)" ( (binary_expression "(uint)param_2 >> 0xc" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)((uint)param_2 >> 6) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)((uint)param_2 >> 6) & 0x3f) + 0x80" (parenthesized_expression "((byte)((uint)param_2 >> 6) & 0x3f)" ( (binary_expression "(byte)((uint)param_2 >> 6) & 0x3f" (call_expression "(byte)((uint)param_2 >> 6)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "((uint)param_2 >> 6)" ( (binary_expression "(uint)param_2 >> 6" (cast_expression "(uint)param_2" ( (type_descriptor "uint" type_identifier) ) identifier) >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = *(char **)param_1;" (assignment_expression "pcVar2 = *(char **)param_1" identifier = (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "*(char **)param_1 = pcVar2 + 1;" (assignment_expression "*(char **)param_1 = pcVar2 + 1" (pointer_expression "*(char **)param_1" * (cast_expression "(char **)param_1" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) (expression_statement "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)param_2 & 0x3f) + 0x80" (parenthesized_expression "((byte)param_2 & 0x3f)" ( (binary_expression "(byte)param_2 & 0x3f" (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier) & number_literal) )) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit "undefined8 FUN_003b7390(long *param_1,uint param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}\n\n" (function_definition "undefined8 FUN_003b7390(long *param_1,uint param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" type_identifier (function_declarator "FUN_003b7390(long *param_1,uint param_2)" identifier (parameter_list "(long *param_1,uint param_2)" ( (parameter_declaration "long *param_1" (sized_type_specifier "long" long) (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" if (parenthesized_expression "(param_2 < 0x80)" ( (binary_expression "param_2 < 0x80" identifier < number_literal) )) (compound_statement "{\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" { (expression_statement "pbVar1 = (byte *)*param_1;" (assignment_expression "pbVar1 = (byte *)*param_1" identifier = (cast_expression "(byte *)*param_1" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }" if (parenthesized_expression "(pbVar1 == (byte *)param_1[1])" ( (binary_expression "pbVar1 == (byte *)param_1[1]" identifier == (cast_expression "(byte *)param_1[1]" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (subscript_expression "param_1[1]" identifier [ number_literal ]))) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pbVar1 + 1);" (assignment_expression "*param_1 = (long)(pbVar1 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pbVar1 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pbVar1 + 1)" ( (binary_expression "pbVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "*pbVar1 = (byte)param_2;" (assignment_expression "*pbVar1 = (byte)param_2" (pointer_expression "*pbVar1" * identifier) = (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier)) ;) (return_statement "return 1;" return number_literal ;) })) (if_statement "if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" if (parenthesized_expression "(param_2 < 0x800)" ( (binary_expression "param_2 < 0x800" identifier < number_literal) )) (compound_statement "{\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }" { (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 2)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 2" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 6) + -0x40;" (assignment_expression "*pcVar2 = (char)(param_2 >> 6) + -0x40" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 6) + -0x40" (cast_expression "(char)(param_2 >> 6)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 6)" ( (binary_expression "param_2 >> 6" identifier >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" else (compound_statement "{\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" { (if_statement "if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" if (parenthesized_expression "(param_2 < 0x10000)" ( (binary_expression "param_2 < 0x10000" identifier < number_literal) )) (compound_statement "{\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }" { (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 3)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 3" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 0xc) + -0x20;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0xc) + -0x20" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 0xc) + -0x20" (cast_expression "(char)(param_2 >> 0xc)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 0xc)" ( (binary_expression "param_2 >> 0xc" identifier >> number_literal) ))) + number_literal)) ;) }) (else_clause "else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" else (compound_statement "{\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" { (if_statement "if (0x10ffff < param_2) {\n        return 0;\n      }" if (parenthesized_expression "(0x10ffff < param_2)" ( (binary_expression "0x10ffff < param_2" number_literal < identifier) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }" if (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 4)" ( (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 4" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" ( identifier )) (argument_list "(param_1[1] - (long)pcVar2)" ( (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (cast_expression "(long)pcVar2" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) ))) < number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = (char)(param_2 >> 0x12) + -0x10;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0x12) + -0x10" (pointer_expression "*pcVar2" * identifier) = (binary_expression "(char)(param_2 >> 0x12) + -0x10" (cast_expression "(char)(param_2 >> 0x12)" ( (type_descriptor "char" primitive_type) ) (parenthesized_expression "(param_2 >> 0x12)" ( (binary_expression "param_2 >> 0x12" identifier >> number_literal) ))) + number_literal)) ;) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 0xc) & 0x3f)" ( (binary_expression "(byte)(param_2 >> 0xc) & 0x3f" (call_expression "(byte)(param_2 >> 0xc)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(param_2 >> 0xc)" ( (binary_expression "param_2 >> 0xc" identifier >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)(param_2 >> 6) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 6) & 0x3f)" ( (binary_expression "(byte)(param_2 >> 6) & 0x3f" (call_expression "(byte)(param_2 >> 6)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(param_2 >> 6)" ( (binary_expression "param_2 >> 6" identifier >> number_literal) ))) & number_literal) )) + number_literal)) ;) }))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" identifier = (cast_expression "(char *)*param_1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" * identifier) = (cast_expression "(long)(pcVar2 + 1)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (parenthesized_expression "(pcVar2 + 1)" ( (binary_expression "pcVar2 + 1" identifier + number_literal) )))) ;) (expression_statement "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80" (pointer_expression "*pcVar2" * identifier) = (binary_expression "((byte)param_2 & 0x3f) + 0x80" (parenthesized_expression "((byte)param_2 & 0x3f)" ( (binary_expression "(byte)param_2 & 0x3f" (cast_expression "(byte)param_2" ( (type_descriptor "byte" type_identifier) ) identifier) & number_literal) )) + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration (sized_type_specifier long) (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (subscript_expression IDENT [ LIT ]))) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (return_statement return LIT ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (subscript_expression IDENT [ LIT ]) - (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT)) ))) < LIT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT >> LIT) ))) + LIT)) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (subscript_expression IDENT [ LIT ]) - (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT)) ))) < LIT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT >> LIT) ))) + LIT)) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (subscript_expression IDENT [ LIT ]) - (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT)) ))) < LIT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT >> LIT) ))) + LIT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT >> LIT) ))) & LIT) )) + LIT)) ;) }))) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT >> LIT) ))) & LIT) )) + LIT)) ;) }))) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) & LIT) )) + LIT)) ;) (return_statement return LIT ;) })))
(function_definition "undefined8 FUN_003b7390(long *param_1,uint param_2)\n\n{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" (type_identifier "undefined8") (function_declarator "FUN_003b7390(long *param_1,uint param_2)" (identifier "FUN_003b7390") (parameter_list "(long *param_1,uint param_2)" (( "(") (parameter_declaration "long *param_1" (sized_type_specifier "long" (long "long")) (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "uint param_2" (type_identifier "uint") (identifier "param_2")) () ")"))) (compound_statement "{\n  byte *pbVar1;\n  char *pcVar2;\n  \n  if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }\n  if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }\n  pcVar2 = (char *)*param_1;\n  *param_1 = (long)(pcVar2 + 1);\n  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;\n  return 1;\n}" ({ "{") (declaration "byte *pbVar1;" (type_identifier "byte") (pointer_declarator "*pbVar1" (* "*") (identifier "pbVar1")) (; ";")) (declaration "char *pcVar2;" (primitive_type "char") (pointer_declarator "*pcVar2" (* "*") (identifier "pcVar2")) (; ";")) (if_statement "if (param_2 < 0x80) {\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" (if "if") (parenthesized_expression "(param_2 < 0x80)" (( "(") (binary_expression "param_2 < 0x80" (identifier "param_2") (< "<") (number_literal "0x80")) () ")")) (compound_statement "{\n    pbVar1 = (byte *)*param_1;\n    if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }\n    *param_1 = (long)(pbVar1 + 1);\n    *pbVar1 = (byte)param_2;\n    return 1;\n  }" ({ "{") (expression_statement "pbVar1 = (byte *)*param_1;" (assignment_expression "pbVar1 = (byte *)*param_1" (identifier "pbVar1") (= "=") (cast_expression "(byte *)*param_1" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (if_statement "if (pbVar1 == (byte *)param_1[1]) {\n      return 0;\n    }" (if "if") (parenthesized_expression "(pbVar1 == (byte *)param_1[1])" (( "(") (binary_expression "pbVar1 == (byte *)param_1[1]" (identifier "pbVar1") (== "==") (cast_expression "(byte *)param_1[1]" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")))) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*param_1 = (long)(pbVar1 + 1);" (assignment_expression "*param_1 = (long)(pbVar1 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pbVar1 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pbVar1 + 1)" (( "(") (binary_expression "pbVar1 + 1" (identifier "pbVar1") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pbVar1 = (byte)param_2;" (assignment_expression "*pbVar1 = (byte)param_2" (pointer_expression "*pbVar1" (* "*") (identifier "pbVar1")) (= "=") (cast_expression "(byte)param_2" (( "(") (type_descriptor "byte" (type_identifier "byte")) () ")") (identifier "param_2"))) (; ";")) (return_statement "return 1;" (return "return") (number_literal "1") (; ";")) (} "}"))) (if_statement "if (param_2 < 0x800) {\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }\n  else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" (if "if") (parenthesized_expression "(param_2 < 0x800)" (( "(") (binary_expression "param_2 < 0x800" (identifier "param_2") (< "<") (number_literal "0x800")) () ")")) (compound_statement "{\n    pcVar2 = (char *)*param_1;\n    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = (char)(param_2 >> 6) + -0x40;\n  }" ({ "{") (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 2) {\n      return 0;\n    }" (if "if") (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 2)" (( "(") (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 2" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" (( "(") (identifier "ulong") () ")")) (argument_list "(param_1[1] - (long)pcVar2)" (( "(") (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (- "-") (cast_expression "(long)pcVar2" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "pcVar2"))) () ")"))) (< "<") (number_literal "2")) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = (char)(param_2 >> 6) + -0x40;" (assignment_expression "*pcVar2 = (char)(param_2 >> 6) + -0x40" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "(char)(param_2 >> 6) + -0x40" (cast_expression "(char)(param_2 >> 6)" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (parenthesized_expression "(param_2 >> 6)" (( "(") (binary_expression "param_2 >> 6" (identifier "param_2") (>> ">>") (number_literal "6")) () ")"))) (+ "+") (number_literal "-0x40"))) (; ";")) (} "}")) (else_clause "else {\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" (else "else") (compound_statement "{\n    if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }\n    pcVar2 = (char *)*param_1;\n    *param_1 = (long)(pcVar2 + 1);\n    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;\n  }" ({ "{") (if_statement "if (param_2 < 0x10000) {\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }\n    else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" (if "if") (parenthesized_expression "(param_2 < 0x10000)" (( "(") (binary_expression "param_2 < 0x10000" (identifier "param_2") (< "<") (number_literal "0x10000")) () ")")) (compound_statement "{\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;\n    }" ({ "{") (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 3) {\n        return 0;\n      }" (if "if") (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 3)" (( "(") (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 3" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" (( "(") (identifier "ulong") () ")")) (argument_list "(param_1[1] - (long)pcVar2)" (( "(") (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (- "-") (cast_expression "(long)pcVar2" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "pcVar2"))) () ")"))) (< "<") (number_literal "3")) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = (char)(param_2 >> 0xc) + -0x20;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0xc) + -0x20" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "(char)(param_2 >> 0xc) + -0x20" (cast_expression "(char)(param_2 >> 0xc)" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (parenthesized_expression "(param_2 >> 0xc)" (( "(") (binary_expression "param_2 >> 0xc" (identifier "param_2") (>> ">>") (number_literal "0xc")) () ")"))) (+ "+") (number_literal "-0x20"))) (; ";")) (} "}")) (else_clause "else {\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" (else "else") (compound_statement "{\n      if (0x10ffff < param_2) {\n        return 0;\n      }\n      pcVar2 = (char *)*param_1;\n      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;\n      pcVar2 = (char *)*param_1;\n      *param_1 = (long)(pcVar2 + 1);\n      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;\n    }" ({ "{") (if_statement "if (0x10ffff < param_2) {\n        return 0;\n      }" (if "if") (parenthesized_expression "(0x10ffff < param_2)" (( "(") (binary_expression "0x10ffff < param_2" (number_literal "0x10ffff") (< "<") (identifier "param_2")) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (if_statement "if ((ulong)(param_1[1] - (long)pcVar2) < 4) {\n        return 0;\n      }" (if "if") (parenthesized_expression "((ulong)(param_1[1] - (long)pcVar2) < 4)" (( "(") (binary_expression "(ulong)(param_1[1] - (long)pcVar2) < 4" (call_expression "(ulong)(param_1[1] - (long)pcVar2)" (parenthesized_expression "(ulong)" (( "(") (identifier "ulong") () ")")) (argument_list "(param_1[1] - (long)pcVar2)" (( "(") (binary_expression "param_1[1] - (long)pcVar2" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (- "-") (cast_expression "(long)pcVar2" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "pcVar2"))) () ")"))) (< "<") (number_literal "4")) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = (char)(param_2 >> 0x12) + -0x10;" (assignment_expression "*pcVar2 = (char)(param_2 >> 0x12) + -0x10" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "(char)(param_2 >> 0x12) + -0x10" (cast_expression "(char)(param_2 >> 0x12)" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (parenthesized_expression "(param_2 >> 0x12)" (( "(") (binary_expression "param_2 >> 0x12" (identifier "param_2") (>> ">>") (number_literal "0x12")) () ")"))) (+ "+") (number_literal "-0x10"))) (; ";")) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "((byte)(param_2 >> 0xc) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 0xc) & 0x3f)" (( "(") (binary_expression "(byte)(param_2 >> 0xc) & 0x3f" (call_expression "(byte)(param_2 >> 0xc)" (parenthesized_expression "(byte)" (( "(") (identifier "byte") () ")")) (argument_list "(param_2 >> 0xc)" (( "(") (binary_expression "param_2 >> 0xc" (identifier "param_2") (>> ">>") (number_literal "0xc")) () ")"))) (& "&") (number_literal "0x3f")) () ")")) (+ "+") (number_literal "0x80"))) (; ";")) (} "}")))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "((byte)(param_2 >> 6) & 0x3f) + 0x80" (parenthesized_expression "((byte)(param_2 >> 6) & 0x3f)" (( "(") (binary_expression "(byte)(param_2 >> 6) & 0x3f" (call_expression "(byte)(param_2 >> 6)" (parenthesized_expression "(byte)" (( "(") (identifier "byte") () ")")) (argument_list "(param_2 >> 6)" (( "(") (binary_expression "param_2 >> 6" (identifier "param_2") (>> ">>") (number_literal "6")) () ")"))) (& "&") (number_literal "0x3f")) () ")")) (+ "+") (number_literal "0x80"))) (; ";")) (} "}")))) (expression_statement "pcVar2 = (char *)*param_1;" (assignment_expression "pcVar2 = (char *)*param_1" (identifier "pcVar2") (= "=") (cast_expression "(char *)*param_1" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (expression_statement "*param_1 = (long)(pcVar2 + 1);" (assignment_expression "*param_1 = (long)(pcVar2 + 1)" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(long)(pcVar2 + 1)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (parenthesized_expression "(pcVar2 + 1)" (( "(") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80;" (assignment_expression "*pcVar2 = ((byte)param_2 & 0x3f) + 0x80" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (binary_expression "((byte)param_2 & 0x3f) + 0x80" (parenthesized_expression "((byte)param_2 & 0x3f)" (( "(") (binary_expression "(byte)param_2 & 0x3f" (cast_expression "(byte)param_2" (( "(") (type_descriptor "byte" (type_identifier "byte")) () ")") (identifier "param_2")) (& "&") (number_literal "0x3f")) () ")")) (+ "+") (number_literal "0x80"))) (; ";")) (return_statement "return 1;" (return "return") (number_literal "1") (; ";")) (} "}")))

/* std::(anonymous namespace)::write_utf8_code_point(std::(anonymous namespace)::range<char, true>&,
   char32_t) */

type_1 std::(anonymous_namespace)::function_1(type_2 *var_2,type_3 param_2)

{
  type_4 *var_1;
  char *var_3;
  
  if ((type_5)param_2 < 0x80) {
    var_1 = *(type_4 **)var_2;
    if (var_1 == *(type_4 **)(var_2 + 8)) {
      return 0;
    }
    *(type_4 **)var_2 = var_1 + 1;
    *var_1 = (type_4)param_2;
    return 1;
  }
  if ((type_5)param_2 < 0x800) {
    var_3 = *(char **)var_2;
    if ((ulong)(*(long *)(var_2 + 8) - (long)var_3) < 2) {
      return 0;
    }
    *(char **)var_2 = var_3 + 1;
    *var_3 = (char)((type_5)param_2 >> 6) + -0x40;
  }
  else {
    if ((type_5)param_2 < 0x10000) {
      var_3 = *(char **)var_2;
      if ((ulong)(*(long *)(var_2 + 8) - (long)var_3) < 3) {
        return 0;
      }
      *(char **)var_2 = var_3 + 1;
      *var_3 = (char)((type_5)param_2 >> 0xc) + -0x20;
    }
    else {
      if (0x10ffff < (type_5)param_2) {
        return 0;
      }
      var_3 = *(char **)var_2;
      if ((ulong)(*(long *)(var_2 + 8) - (long)var_3) < 4) {
        return 0;
      }
      *(char **)var_2 = var_3 + 1;
      *var_3 = (char)((type_5)param_2 >> 0x12) + -0x10;
      var_3 = *(char **)var_2;
      *(char **)var_2 = var_3 + 1;
      *var_3 = ((type_4)((type_5)param_2 >> 0xc) & 0x3f) + 0x80;
    }
    var_3 = *(char **)var_2;
    *(char **)var_2 = var_3 + 1;
    *var_3 = ((type_4)((type_5)param_2 >> 6) & 0x3f) + 0x80;
  }
  var_3 = *(char **)var_2;
  *(char **)var_2 = var_3 + 1;
  *var_3 = ((type_4)param_2 & 0x3f) + 0x80;
  return 1;
}


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

undefined8 MASKED(long *param_1,uint param_2)

{
  byte *pbVar1;
  char *pcVar2;
  
  if (param_2 < 0x80) {
    pbVar1 = (byte *)*param_1;
    if (pbVar1 == (byte *)param_1[1]) {
      return 0;
    }
    *param_1 = (long)(pbVar1 + 1);
    *pbVar1 = (byte)param_2;
    return 1;
  }
  if (param_2 < 0x800) {
    pcVar2 = (char *)*param_1;
    if ((ulong)(param_1[1] - (long)pcVar2) < 2) {
      return 0;
    }
    *param_1 = (long)(pcVar2 + 1);
    *pcVar2 = (char)(param_2 >> 6) + -0x40;
  }
  else {
    if (param_2 < 0x10000) {
      pcVar2 = (char *)*param_1;
      if ((ulong)(param_1[1] - (long)pcVar2) < 3) {
        return 0;
      }
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = (char)(param_2 >> 0xc) + -0x20;
    }
    else {
      if (0x10ffff < param_2) {
        return 0;
      }
      pcVar2 = (char *)*param_1;
      if ((ulong)(param_1[1] - (long)pcVar2) < 4) {
        return 0;
      }
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = (char)(param_2 >> 0x12) + -0x10;
      pcVar2 = (char *)*param_1;
      *param_1 = (long)(pcVar2 + 1);
      *pcVar2 = ((byte)(param_2 >> 0xc) & 0x3f) + 0x80;
    }
    pcVar2 = (char *)*param_1;
    *param_1 = (long)(pcVar2 + 1);
    *pcVar2 = ((byte)(param_2 >> 6) & 0x3f) + 0x80;
  }
  pcVar2 = (char *)*param_1;
  *param_1 = (long)(pcVar2 + 1);
  *pcVar2 = ((byte)param_2 & 0x3f) + 0x80;
  return 1;
}

