user: What would the C source look like for the assembly code provided here:

```asm
<ansi_terminal>:
  endbr64
  push   %r13
  lea    D41(%rip),%rdi
  push   %r12
  push   %rbp
  call   <getenv@plt>
  mov    $0x1,%edi
  mov    %rax,%rbp
  call   <isatty@plt>
  test   %eax,%eax
  jne    L140
L130:
  xor    %eax,%eax
L76:
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  xchg   %ax,%ax
L140:
  mov    $0x2,%edi
  call   <isatty@plt>
  test   %rbp,%rbp
  je     L130
  test   %eax,%eax
  je     L130
  lea    D32(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  jne    L66
L9:
  pop    %rbp
  mov    $0x1,%eax
  pop    %r12
  pop    %r13
  ret
  nopw   0x0(%rax,%rax,1)
L66:
  lea    D72(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D143(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D29(%rip),%r12
  mov    %rbp,%rdi
  mov    %r12,%rsi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D109(%rip),%r13
  mov    %rbp,%rdi
  mov    %r13,%rsi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D54(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D46(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D138(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D55(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D78(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D116(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D102(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  mov    %r12,%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  mov    %r13,%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D107(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  je     L9
  lea    D137(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcasecmp@plt>
  test   %rax,%rax
  sete   %al
  jmp    L76
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D41
type_infered: string
name: extract_symbolic_data
arguments: data_label: D32
type_infered: string
name: extract_symbolic_data
arguments: data_label: D72
type_infered: string
name: extract_symbolic_data
arguments: data_label: D143
type_infered: string
name: extract_symbolic_data
arguments: data_label: D29
type_infered: string
name: extract_symbolic_data
arguments: data_label: D109
type_infered: string
name: extract_symbolic_data
arguments: data_label: D54
type_infered: string
name: extract_symbolic_data
arguments: data_label: D46
type_infered: string
name: extract_symbolic_data
arguments: data_label: D138
type_infered: string
name: extract_symbolic_data
arguments: data_label: D55
type_infered: string
name: extract_symbolic_data
arguments: data_label: D78
type_infered: string
name: extract_symbolic_data
arguments: data_label: D116
type_infered: string
name: extract_symbolic_data
arguments: data_label: D102
type_infered: string
name: extract_symbolic_data
arguments: data_label: D107
type_infered: string
name: extract_symbolic_data
arguments: data_label: D137
type_infered: string

tool: D41: TERM

tool: D32: ansi

tool: D72: console

tool: D143: con80x25

tool: D29: linux

tool: D109: linux-80x25

tool: D54: screen

tool: D46: xterm

tool: D138: xterm-color

tool: D55: xterm-256color

tool: D78: xterm-16color

tool: D116: rxvt

tool: D102: konsole

tool: D107: konsole-16color

tool: D137: rxvt-16color

assistant: ```c
char ansi_terminal(void) {
  const char *term = getenv("TERM");
  if (!isatty(1) || !isatty(2))
    return 0;
  if (!term)
    return 0;
  if (strcasecmp(term, "ansi") == 0)
    return 1;
  if (strcasecmp(term, "console") == 0 || strcasecmp(term, "con80x25") == 0 || strcasecmp(term, "linux") == 0 || strcasecmp(term, "linux-80x25") == 0)
    return 1;
  if (strcasecmp(term, "screen") == 0)
    return 1;
  if (strcasecmp(term, "xterm") == 0 || strcasecmp(term, "xterm-color") == 0 || strcasecmp(term, "xterm-256color") == 0 || strcasecmp(term, "xterm-16color") == 0)
    return 1;
  if (strcasecmp(term, "rxvt") == 0 || strcasecmp(term, "konsole") == 0 || strcasecmp(term, "linux") == 0 || strcasecmp(term, "linux-80x25") == 0 || strcasecmp(term, "konsole-16color") == 0 || strcasecmp(term, "rxvt-16color") == 0)
    return 1;
  return 0;
}
```