> ## 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-MATCH-0003: Invalid class pattern field.

> Invalid class pattern field.

`SIFR-MATCH-0003` belongs to the **Pattern matching** diagnostic family. It means: invalid class pattern field.

## Why It Happens

The pattern match cannot be proven valid. Check exhaustiveness, guard types, class-pattern fields, and supported pattern forms.

<Info>
  Use `sifr --explain SIFR-MATCH-0003` 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}
match value:
    case 0:
        label = "zero"
```

## How To Fix It

Make patterns supported, guards boolean, field names valid, and matches exhaustive where required.

## Fixed Code

```python theme={null}
match value:
    case 0:
        label = "zero"
    case _:
        label = "other"
```

## Details

| Field                  | Value                                                      |
| ---------------------- | ---------------------------------------------------------- |
| Code                   | `SIFR-MATCH-0003`                                          |
| Family                 | `MATCH`                                                    |
| Severity               | Error                                                      |
| Stability              | stable                                                     |
| Owner                  | `sifr_lowering::lower::statements`                         |
| Representative fixture | `crates/sifr/tests/e2e/fail/match_invalid_field_name.sifr` |

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