pub fn unused_variable_hints(
index: &SymbolIndex,
line_index: &LineIndex,
) -> Vec<Diagnostic>Expand description
Hints for Let bindings nothing ever reads.
A definition counts as used when any reference RESOLVING TO IT sits at a different span than the definition itself (the definition site indexes a self-reference, which does not count). Variables only — an unused parameter can be a deliberate interface, and fields/variants are shape, not dataflow. Severity HINT + the UNNECESSARY tag: editors fade the binding rather than shouting about it.