stan-0.2.0.0: Haskell STatic ANalyser

Copyright | (c) 2020 Kowainik
License | MPL-2.0
Maintainer | Kowainik <xrom.xkov@gmail.com>
Safe Haskell | None
Language | Haskell2010

Stan.Inspection.AntiPattern

Contents

- Anti-pattern inspections
  - Anti-pattern `[0 .. length xs]`
  - Anti-pattern `foldl`
  - Anti-pattern `pack`
  - Anti-pattern slow `size` for `HashMap`
  - Anti-pattern slow `size` for `HashSet`
  - Anti-pattern: Lazy fields
  - Anti-pattern: Foldable methods on tuples, `Maybe`, `Either`
  - Anti-pattern: slow `length` for `Text`
  - Anti-pattern: Slow `nub` for lists
  - Anti-pattern: Slow `for_` on ranges
  - Anti-pattern: `</>` for URLs
  - Anti-pattern: unsafe functions
  - Anti-pattern: Pattern-matching on `_`
  - Anti-pattern: use `compare`
  - Anti-pattern: Slashes in paths
- All inspections

Description

Contains all `Inspection`s for known anti-patterns.

The anti-pattern inspections are in ranges:

-     STAN-0201 .. STAN-0300

Synopsis

- stan0201 :: Inspection
- stan0202 :: Inspection
- stan0203 :: Inspection
- stan0204 :: Inspection
- stan0205 :: Inspection
- stan0206 :: Inspection
- stan0207 :: Inspection
- stan0208 :: Inspection
- stan0209 :: Inspection
- stan0210 :: Inspection
- stan0211 :: Inspection
- stan0212 :: Inspection
- stan0213 :: Inspection
- stan0214 :: Inspection
- stan0215 :: Inspection
- antiPatternInspectionsMap :: InspectionsMap

# Anti-pattern inspections

### Anti-pattern `[0 .. length xs]`

stan0201 :: Inspection #

`Inspection` — `[0 .. length xs]` `STAN-0201`.

### Anti-pattern `foldl`

stan0202 :: Inspection #

`Inspection` — `foldl` `STAN-0202`.

### Anti-pattern `pack`

stan0203 :: Inspection #

`Inspection` — `pack` `STAN-0203`.

### Anti-pattern slow `size` for `HashMap`

stan0204 :: Inspection #

`Inspection` — slow `size` and `length` `STAN-0204`.

### Anti-pattern slow `size` for `HashSet`

stan0205 :: Inspection #

`Inspection` — slow `size` `STAN-0205`.

### Anti-pattern: Lazy fields

stan0206 :: Inspection #

`Inspection` — missing strictness declaration `STAN-0206`.

### Anti-pattern: Foldable methods on tuples, `Maybe`, `Either`

stan0207 :: Inspection #

`Inspection` — `Foldable` methods on possibly error-prone structures `STAN-0207`.

### Anti-pattern: slow `length` for `Text`

stan0208 :: Inspection #

`Inspection` — slow `length` for `Text` `STAN-0208`.

### Anti-pattern: Slow `nub` for lists

stan0209 :: Inspection #

`Inspection` — slow `nub` for lists `STAN-0209`.

### Anti-pattern: Slow `for_` on ranges

stan0210 :: Inspection #

`Inspection` — slow `for_` and `forM_` for ranges `STAN-0210`.

### Anti-pattern: `</>` for URLs

stan0211 :: Inspection #

`Inspection` — `/` on URLs `STAN-0211`.

### Anti-pattern: unsafe functions

stan0212 :: Inspection #

`Inspection` — usage of `unsafe*` functions `STAN-0212`.

### Anti-pattern: Pattern-matching on `_`

stan0213 :: Inspection #

`Inspection` — Pattent matching on `_` for sum types — `STAN-0213`.

### Anti-pattern: use `compare`

stan0214 :: Inspection #

`Inspection` — use `compare` `STAN-0214`.

### Anti-pattern: Slashes in paths

stan0215 :: Inspection #

`Inspection` — Slashes in paths `STAN-0215`.

# All inspections

antiPatternInspectionsMap :: InspectionsMap #

All anti-pattern `Inspection`s map from `Id`s.