Diagnostics

Every diagnostic Nish prints carries a stable code, the code field of its --json object. A code is a promise: it names the same rule in every release, and a retired rule keeps its number so no other rule is ever handed it. These pages list all 981, one page per band: the 4 of band 0, which no rule matches, and the 977 rules src/codes.ts holds, 70 of them retired.

A rule is matched by a fragment of its message: the longest literal run of the message's template, with the names, types and counts it interpolates cut out. The fragment is matched as a substring, so … marks where the message goes on. Each example is a program from tests/wordings/ that the suite compiles, and the message it gets, word for word. Reading diagnostics in the guide says how to act on one; the command-line reference lists the flags that turn the warnings on and off.