Skip to content

Commit

Permalink
[#448] Add -Wnoncanonical-monad-instances (#516)
Browse files Browse the repository at this point in the history
* [#448] Add -Wnoncanonical-monad-instances

* [#448] Add new warning to README
  • Loading branch information
gdziadkiewicz authored Oct 26, 2020
1 parent d2ab6bd commit b56aada
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 12 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ Features related to the structure and content of the generated projects.
-Wincomplete-uni-patterns
-Wincomplete-record-updates
-Wredundant-constraints
-Wnoncanonical-monad-instances
-fhide-source-paths (GHC ⩾ 8.2)
-Wmissing-export-lists (GHC ⩾ 8.4)
-Wpartial-fields (GHC ⩾ 8.4)
Expand Down
1 change: 1 addition & 0 deletions summoner-cli/examples/cabal-full/cabal-full.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ common common-options
-Wincomplete-uni-patterns
-Wincomplete-record-updates
-Wredundant-constraints
-Wnoncanonical-monad-instances
if impl(ghc >= 8.2)
ghc-options: -fhide-source-paths
if impl(ghc >= 8.4)
Expand Down
1 change: 1 addition & 0 deletions summoner-cli/examples/cabal-minimal/cabal-minimal.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ common common-options
-Wincomplete-uni-patterns
-Wincomplete-record-updates
-Wredundant-constraints
-Wnoncanonical-monad-instances
if impl(ghc >= 8.2)
ghc-options: -fhide-source-paths
if impl(ghc >= 8.4)
Expand Down
1 change: 1 addition & 0 deletions summoner-cli/examples/stack-full/stack-full.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ common common-options
-Wincomplete-uni-patterns
-Wincomplete-record-updates
-Wredundant-constraints
-Wnoncanonical-monad-instances
if impl(ghc >= 8.2)
ghc-options: -fhide-source-paths
if impl(ghc >= 8.4)
Expand Down
1 change: 1 addition & 0 deletions summoner-cli/src/Summoner/Template/Cabal.hs
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ cabalFile Settings{..} = File (toString settingsRepo ++ ".cabal") cabalFileConte
, " -Wincomplete-uni-patterns"
, " -Wincomplete-record-updates"
, " -Wredundant-constraints"
, " -Wnoncanonical-monad-instances"
, " if impl(ghc >= 8.2)"
, " ghc-options: -fhide-source-paths"
, " if impl(ghc >= 8.4)"
Expand Down
10 changes: 4 additions & 6 deletions summoner-cli/summoner.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,10 @@ common common-options
-Widentities
-Wincomplete-uni-patterns
-Wincomplete-record-updates
if impl(ghc >= 8.0)
ghc-options: -Wredundant-constraints
if impl(ghc >= 8.2)
ghc-options: -fhide-source-paths
if impl(ghc >= 8.4)
ghc-options: -Wmissing-export-lists
-Wredundant-constraints
-Wnoncanonical-monad-instances
-fhide-source-paths
-Wmissing-export-lists
-Wpartial-fields
if impl(ghc >= 8.8)
ghc-options: -Wmissing-deriving-strategies
Expand Down
10 changes: 4 additions & 6 deletions summoner-tui/summoner-tui.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,10 @@ common common-options
-Widentities
-Wincomplete-uni-patterns
-Wincomplete-record-updates
if impl(ghc >= 8.0)
ghc-options: -Wredundant-constraints
if impl(ghc >= 8.2)
ghc-options: -fhide-source-paths
if impl(ghc >= 8.4)
ghc-options: -Wmissing-export-lists
-Wredundant-constraints
-Wnoncanonical-monad-instances
-fhide-source-paths
-Wmissing-export-lists
-Wpartial-fields
if impl(ghc >= 8.8)
ghc-options: -Wmissing-deriving-strategies
Expand Down

0 comments on commit b56aada

Please sign in to comment.