# XO0110: unused local binding or import

A local `let` or `var` binding, a local constant, a pattern binding, or an import that is never read is an error, because dead names usually mean a forgotten step. Function and closure parameters, names starting with `_`, and `_` itself are not covered. A `var` that is only assigned and never read also counts as unused. `xo fix` removes unused bindings. See core 3.1.

## Example

```xo
use std/json

fn f() -> Int {
  let x = 1
  2
}
```

## Fix

```xo
fn f() -> Int {
  let x = 1
  x + 1
}
```

Run `xo explain XO0110` for this text in a terminal, or see
[section 10.6 of the specification](../../spec/core/#106-diagnostic-codes).

