Skip to content

Commit e878c20

Browse files
committed
Better language extensions/warnings (fixes #85)
1 parent 3a46135 commit e878c20

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

etc/template/package.yaml

+11-8
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,24 @@ dependencies:
2323
- base >= 4.10 && < 10
2424
- rio >= 0.1.1.0
2525

26+
ghc-options:
27+
- -Wall
28+
- -Wcompat
29+
- -Wincomplete-record-updates
30+
- -Wincomplete-uni-patterns
31+
- -Wredundant-constraints
32+
33+
- -threaded
34+
- -rtsopts
35+
- -with-rtsopts=-N
36+
2637
library:
2738
source-dirs: src
2839

2940
executables:
3041
PROJECTNAME-exe:
3142
main: Main.hs
3243
source-dirs: app
33-
ghc-options:
34-
- -threaded
35-
- -rtsopts
36-
- -with-rtsopts=-N
3744
dependencies:
3845
- PROJECTNAME
3946
- optparse-simple
@@ -42,10 +49,6 @@ tests:
4249
PROJECTNAME-test:
4350
main: Spec.hs
4451
source-dirs: test
45-
ghc-options:
46-
- -threaded
47-
- -rtsopts
48-
- -with-rtsopts=-N
4952
dependencies:
5053
- PROJECTNAME
5154
- hspec

rio/README.md

+3
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ GeneralizedNewtypeDeriving
152152
InstanceSigs
153153
KindSignatures
154154
LambdaCase
155+
MonadFailDesugaring
155156
MultiParamTypeClasses
156157
MultiWayIf
157158
NamedFieldPuns
@@ -178,6 +179,8 @@ Notes on some surprising choices:
178179
* Despite the fact that `OverloadedStrings` can break existing code,
179180
we recommend its usage to encourage avoidance of the `String` data
180181
type. Also, for new code, the risk of breakage is much lower.
182+
* `MonadFailDesugaring` helps prevent partial pattern matches in your
183+
code, see [#85](https://github.com/commercialhaskell/rio/issues/85)
181184

182185
__TODO__ Do we recommend setting in `package.yaml` or in the source
183186
files themselves? Need to discuss and come to a conclusion on this

0 commit comments

Comments
 (0)