# Elem::inhabitation-failed


**Key:** `Elem::inhabitation-failed`

**Category:** inhabitation · **Severity:** error

**Source:** [`src/diag/hints.nix:902`](https://github.com/kleisli-io/nix-effects/blob/main/src/diag/hints.nix#L902)

the element does not inhabit the list's element type

## Example

`Hint::Elem::inhabitation-failed` means the `Elem` position contains a value that does not inhabit the generated type. The example shows the failing form first, then one way to give the checker the missing structure.

```nix
# Bad: a list element does not inhabit the element type.
IntList.validate [ 1 "two" 3 ]

# Better: every element inhabits the element type.
IntList.validate [ 1 2 3 ]

```


---

[← All diagnostic hints](/nix-effects/diag-hints)
