ndmitchell / hlint

Haskell source code suggestions
Other
1.48k stars 195 forks source link

Add hints to use comparing #1603

Closed josephcsible closed 3 months ago

josephcsible commented 5 months ago

This test is failing: https://github.com/ndmitchell/hlint/blob/e0f532a0b958e23044175706b611e45b5aa06889/data/hlint.yaml#L1581 It wants just this to fire: https://github.com/ndmitchell/hlint/blob/e0f532a0b958e23044175706b611e45b5aa06889/data/hlint.yaml#L117 But now "Use comparing" fires too. I'm not sure what the cleanest way to fix this is. What is isCompare doing in that rule exactly?

ndmitchell commented 3 months ago

I think we actually had these hints in the past. But it seems not everyone is convinced by comparing - now the only instances are when you are already using comparing, or there is a significant perf advantage to doing so.

josephcsible commented 3 months ago

Fair enough.