> ## 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-PARSE-0007: Empty or malformed declaration list syntax.

> Empty or malformed declaration list syntax.

`SIFR-PARSE-0007` belongs to the **Parsing** diagnostic family. It means: empty or malformed declaration list syntax.

## Why It Happens

The parser cannot recover a supported Sifr syntax tree from the source. Fix syntax before type, ownership, or package analysis can continue.

<Info>
  Use `sifr --explain SIFR-PARSE-0007` 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}
def main( -> int:
    return 1
```

## How To Fix It

Fix the source syntax first. Parser diagnostics happen before Sifr can reason about types, ownership, or package structure.

## Fixed Code

```python theme={null}
def main() -> int:
    return 1
```

## Details

| Field                  | Value                                                               |
| ---------------------- | ------------------------------------------------------------------- |
| Code                   | `SIFR-PARSE-0007`                                                   |
| Family                 | `PARSE`                                                             |
| Severity               | Error                                                               |
| Stability              | stable                                                              |
| Owner                  | `sifr_driver::frontend::api`                                        |
| Representative fixture | `crates/sifr/tests/e2e/fail/parser_malformed_declaration_list.sifr` |

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