Markdown for LLMs
LDC-E1402 — Requirement on an unknown feature
The source Markdown for this article. Copy it into your assistant or download it as a text file.
# LDC-E1402 — Requirement on an unknown feature
## What it means
A declaration can require a language feature: without that
feature, the declaration must not be read as written. The annotation names
the feature, and the name must come from the feature registry — an
unknown name cannot be allowed through as informational, because a
misspelled requirement would silently stop constraining. The compiler stops at the
annotation and lists the features it knows.
The repair is to name a registered feature, or to drop the requirement. A
requirement on a feature nobody registered constrains nothing.
## Example
```law
language "law.core" version "0.2";
package demo.diagnostics version "0.1.0";
namespace "urn:law:demo:diagnostics";
@requires_feature("nope.nothing")
entity A;
```
## Fix
```law
language "law.core" version "0.2";
package demo.diagnostics version "0.1.0";
namespace "urn:law:demo:diagnostics";
entity A;
```
## Engine message
The engine reports this in its own wording:
```text
example.law:5:1: error LDC-E1402: feature "nope.nothing" is absent from the registry (§26): an unknown gate cannot be treated as informational — known: law.cert/0.1, law.cnl/0.1, law.decision/0.1, law.deontic/0.1, law.evidence_policy/0.1, law.layers/0.1, law.params/0.1, law.precedent/0.2, law.review/0.1, law.units/0.1, law.verb/0.1, law.verb/0.2
```
## Related
- [LDC-E1403](/diagnostics/LDC-E1403/) — a requirement on a reserved feature.
- [LDC-E1401](/diagnostics/LDC-E1401/) — a language line the engine does not support.