Synthetica9 / nix-linter

Linter for the Nix expression language
BSD 3-Clause "New" or "Revised" License
158 stars 16 forks source link

False positive FreeLetInFunc in presence of `inherit` #64

Open mcwitt opened 2 years ago

mcwitt commented 2 years ago

In version 0.2.0.3 (revision 38c4a14681cf3a1e6f098d8b723db503910a28d8), the input

foo:
let inherit (foo) bar;
in bar

results in

Move `let` block outside function definition at foo.nix:1:1-4:1

but the let block can't be moved outside of the function definition since it depends on the argument foo.

Possibly related to #61, #62 ?