curry-language-server icon indicating copy to clipboard operation
curry-language-server copied to clipboard

Add suggestion quick fixes

Open fwcd opened this issue 4 years ago • 1 comments

E.g.

  • Pointfree conversions
    • Eta-reductions (\x -> f x to f)
    • Const (\_ -> x to const x)
    • Void (x >> return () to void x)
    • ...
  • Common library functions (maybe x id m to fromMaybe x m, fst . runState to evalState, snd . runState to execState, foldr1 (?) to anyOf, ...)
  • Redundant dos (do { x } to x)
  • Merging adjacent lets
  • Warn (or at least 'info') about Debug.Trace imports
  • ...

These suggestions could be similar to what hlint suggests.

fwcd avatar Mar 25 '21 23:03 fwcd

These suggestions could also be factored out into a separate linting tool that curry-language-server then integrated (i.e. depends on).

fwcd avatar Mar 03 '22 17:03 fwcd