bolt/rules/suspicious/unused.bend fails
raw source on the hub · import 0x729eecea86ea5a2cdba3a2856a313bca/bolt/rules/suspicious/unused.bend as Unused
rule unused: a name bound by a let, a do-bind, a lambda, or as a parameter
is never used. Pattern binders are exempt: naming every field of
Tok{k, t, l, c} reads better than _. So are names starting with _,
erased parameters (-x), which exist to be unused, a law's for names
(hypotheses the proof takes by position), and the parameters of a foreign
def, which its C and JS bodies read.
7 imports
import Base import ../../src.bend as Src import ../../../lazy/lazy.bend as Lazy import ../../finding.bend as F import ../../../syntax/bind.bend as Bind import ../../../syntax/tree.bend as Tree import ../../../syntax/lex.bend as Lex
The reader could not load this file (at 0x729eecea86ea5a2cdba3a2856a313bca/bolt/config.bend:31). What bend.ts says:
Error:
- expected : a fresh name (duplicate declaration: Set)
- observed : 'Set'
Location:
30 | # a name (a group's or a rule's) at a level
31>| type Set is Data:
| ^^^
32 | Set{name: String, level: Level}