1
1
mirror of https://github.com/github/semantic.git synced 2024-12-11 08:45:48 +03:00
semantic/HLint.hs

34 lines
1004 B
Haskell
Raw Normal View History

import "hint" HLint.Default
import "hint" HLint.Dollar
import "hint" HLint.Generalise
2016-06-06 23:12:23 +03:00
2016-06-24 00:47:01 +03:00
ignore "Use mappend"
ignore "Redundant do"
2016-06-24 00:47:01 +03:00
error "generalize ++" = (++) ==> (<>)
2016-05-26 19:58:59 +03:00
-- AMP fallout
error "generalize mapM" = mapM ==> traverse
error "generalize mapM_" = mapM_ ==> traverse_
error "generalize forM" = forM ==> for
error "generalize forM_" = forM_ ==> for_
error "Avoid return" =
return ==> pure
where note = "return is obsolete as of GHC 7.10"
error "use pure" = free . Pure ==> pure
2016-07-08 00:09:39 +03:00
error "use wrap" = free . Free ==> wrap
2017-09-09 13:50:29 +03:00
error "use extract" = termAnnotation . unTerm ==> extract
2017-09-11 22:24:09 +03:00
error "use unwrap" = termOut . unTerm ==> unwrap
error "avoid head" = head
where note = "head is partial; consider using Data.Maybe.listToMaybe"
error "avoid tail" = tail
where note = "tail is partial; consider pattern-matching"
error "avoid init" = init
where note = "init is partial; consider pattern-matching"
error "avoid last" = last
where note = "last is partial; consider pattern-matching"