> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sifr.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# SIFR-NAME-0005: Duplicate function definition in a module.

> Duplicate function definition in a module.

`SIFR-NAME-0005` belongs to the **Name resolution** diagnostic family. It means: duplicate function definition in a module.

## Why It Happens

A binding, type, function, module, or member name cannot be resolved in the current scope.

<Info>
  Use `sifr --explain SIFR-NAME-0005` locally to see the renderer's exact message template and any machine-applicable suggestions for the compiler version you are running.
</Info>

## Erroneous Code

```python theme={null}
total = subtotal + tax
```

## How To Fix It

Declare or import the name before use, and check whether you meant a module member, type name, or local binding.

## Fixed Code

```python theme={null}
subtotal: int = 10
tax: int = 2
total = subtotal + tax
```

## Details

| Field                  | Value                                                           |
| ---------------------- | --------------------------------------------------------------- |
| Code                   | `SIFR-NAME-0005`                                                |
| Family                 | `NAME`                                                          |
| Severity               | Error                                                           |
| Stability              | stable                                                          |
| Owner                  | `sifr_lowering::lower::module_function_registry`                |
| Representative fixture | `crates/sifr/tests/e2e/fail/duplicate_function_definition.sifr` |

See the [Error Codes index](/diagnostics/error-codes) for the complete catalog.
