user: Please show me the C implementation that matches the assembly code listed below:

```asm
<OUTSTRING>:
  endbr64
  push   %r13
  push   %r12
  xor    %r12d,%r12d
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  sub    $0x8,%rsp
  movzbl (%rdi),%eax
  cmp    $0x22,%al
  je     L279
  cmp    $0x27,%al
  jne    L124
  mov    $0x1,%r12d
L279:
  movsbl 0x1(%rbp),%esi
  lea    0x1(%rbp),%rbx
  test   %sil,%sil
  je     L294
  xor    %ebp,%ebp
  lea    D2(%rip),%r13
  jmp    L136
  nopl   0x0(%rax)
L11:
  cmp    $0x27,%sil
  je     L102
  cmp    $0x5c,%sil
  jne    L19
  test   %ebp,%ebp
  jne    L50
  mov    $0x1,%ebp
  nopl   (%rax)
L229:
  movsbl 0x1(%rbx),%esi
  add    $0x1,%rbx
  test   %sil,%sil
  je     L294
L136:
  cmp    $0x6e,%sil
  je     L276
  jle    L11
  cmp    $0x72,%sil
  je     L51
  cmp    $0x74,%sil
  jne    L73
  test   %ebp,%ebp
  je     L253
  mov    $0x9,%edi
  add    $0x1,%rbx
  xor    %ebp,%ebp
  call   <OUTBYTE@plt>
  movsbl (%rbx),%esi
  test   %sil,%sil
  jne    L136
L294:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopl   0x0(%rax)
L19:
  cmp    $0x22,%sil
  jne    L73
  or     %r12d,%ebp
  je     L294
  mov    $0x22,%edi
  xor    %ebp,%ebp
  call   <OUTBYTE@plt>
  jmp    L229
  nopl   0x0(%rax)
L276:
  test   %ebp,%ebp
  je     L205
  mov    $0xa,%edi
  xor    %ebp,%ebp
  call   <OUTBYTE@plt>
  jmp    L229
  nopl   (%rax)
L102:
  xor    $0x1,%ebp
  and    %r12d,%ebp
  jne    L294
  mov    $0x27,%edi
  call   <OUTBYTE@plt>
  jmp    L229
  nop
L73:
  test   %ebp,%ebp
  jne    L309
L18:
  movsbl (%rbx),%edi
  call   <OUTBYTE@plt>
  jmp    L229
  nopl   0x0(%rax)
L51:
  test   %ebp,%ebp
  je     L132
  mov    $0xd,%edi
  xor    %ebp,%ebp
  call   <OUTBYTE@plt>
  jmp    L229
  nopl   (%rax)
L253:
  mov    $0x74,%edi
  call   <OUTBYTE@plt>
  jmp    L229
  nop
L205:
  mov    $0x6e,%edi
  call   <OUTBYTE@plt>
  jmp    L229
  nop
L132:
  mov    $0x72,%edi
  call   <OUTBYTE@plt>
  jmp    L229
  nop
L309:
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <instruction_error@plt>
  jmp    L18
  nopl   0x0(%rax)
L50:
  mov    $0x5c,%edi
  xor    %ebp,%ebp
  call   <OUTBYTE@plt>
  jmp    L229
  nopl   0x0(%rax)
L124:
  lea    D7(%rip),%rdi
  xor    %eax,%eax
  call   <instruction_error@plt>
  jmp    L279
```

tool_calls: name: retrieve_data
arguments: data_label: D2
type_infered: string
name: retrieve_data
arguments: data_label: D7
type_infered: string

tool: D2: Invalid escape sequence \%c in string

tool: D7: OUTSTRING <INTERNAL ERROR>. Not a string!

assistant: ```c
void OUTSTRING(char *string) {
  int stringt;
  int esc = 0;
  if (*string == '"')
    stringt = 0;
  else if (*string == '\'')
    stringt = 1;
  else
    instruction_error("OUTSTRING <INTERNAL ERROR>. Not a string!");
  string++;
  while (*string) {
    if (*string == '"') {
      if (stringt == 0 && !esc)
        break;
      OUTBYTE('"');
      esc = 0;
    } else if (*string == '\'') {
      if (stringt == 1 && !esc)
        break;
      OUTBYTE('\'');
      esc = 0;
    } else if (*string == 'n') {
      if (esc)
        OUTBYTE('\n');
      else
        OUTBYTE('n');
      esc = 0;
    } else if (*string == 't') {
      if (esc)
        OUTBYTE('\t');
      else
        OUTBYTE('t');
      esc = 0;
    } else if (*string == 'r') {
      if (esc)
        OUTBYTE('\r');
      else
        OUTBYTE('r');
      esc = 0;
    } else if (*string == '\\') {
      if (esc) {
        OUTBYTE('\\');
        esc = 0;
      } else
        esc = 1;
    } else {
      if (esc)
        instruction_error("Invalid escape sequence \\%c in string", *string);
      OUTBYTE(*string);
    }
    string++;
  }
}
```