Skip to content

Commit 4071308

Browse files
authored
Merge pull request #113 from Tritlo/9.8
Update to the 9.6/9.8 GHC API
2 parents 95ab8ab + 77b0bf9 commit 4071308

25 files changed

+811
-595
lines changed

.github/workflows/build-test-deploy.yml

+6-5
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ on:
1212
- '.github/workflows/*.yml'
1313
branches:
1414
- 'master'
15+
- '9.8'
1516
pull_request:
1617
branches:
1718
- 'master'
@@ -29,8 +30,8 @@ jobs:
2930
strategy:
3031
fail-fast: false
3132
matrix:
32-
ghc: ['8.10.7']
33-
cabal: ['3.4.0.0']
33+
ghc: ['9.8', '9.6']
34+
cabal: ['3.10.2.1']
3435

3536
steps:
3637
- uses: actions/checkout@v2
@@ -72,10 +73,10 @@ jobs:
7273
run: cabal build --enable-tests --enable-benchmarks all
7374
- name: Run tests
7475
run: cabal run test
75-
- name: Run slow-test
76-
run: cabal run slow-test
7776
- name: Run benchmark
7877
run: cabal run benchmark
78+
- name: Run slow-test
79+
run: cabal run slow-test
7980

8081
deploy:
8182
runs-on: ubuntu-latest
@@ -120,7 +121,7 @@ jobs:
120121
with:
121122
context: .
122123
build-args: |
123-
"HASKELL_VERSION=8.10.7"
124+
"HASKELL_VERSION=9.6.4"
124125
"PROPR_VERSION=1.0.0"
125126
push: ${{ github.event_name != 'pull_request' }}
126127
tags: ${{ steps.meta.outputs.tags }}

Dockerfile

+1-2
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,7 @@ RUN chmod +x /app/propr
4747
RUN cabal update
4848
COPY ./check-helpers /app/check-helpers
4949
WORKDIR /app/check-helpers
50-
RUN cabal install --lib check-helpers
51-
RUN cabal install --lib random QuickCheck
50+
RUN cabal install --lib check-helpers random QuickCheck
5251

5352
ENV LOG_LEVEL=INFO
5453
ENV REPAIR_TARGET=/input

PropR.cabal

+81-113
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1+
cabal-version: 3.8
12
name: PropR
2-
cabal-version: 1.24
33
build-type: Simple
44
version: 1.0.0
55
author: Matthías Páll Gissurarson
@@ -11,150 +11,118 @@ category: Compiler Plugin
1111
license: MIT
1212
license-file: LICENSE
1313

14-
1514
library
16-
default-language: Haskell2010
15+
default-language: GHC2021
1716
ghc-options: -O2
1817
hs-source-dirs: src/
1918
exposed-modules: PropR
20-
PropR.Configuration,
21-
PropR.Eval,
22-
PropR.Plugin,
23-
PropR.Repair,
24-
PropR.Check,
25-
PropR.Traversals,
26-
PropR.Types,
27-
PropR.Diff,
28-
PropR.Util,
29-
PropR.Search,
30-
PropR.Search.PseudoGenetic,
31-
PropR.Search.Genetic,
32-
PropR.Search.Random,
33-
PropR.Search.Exhaustive,
19+
PropR.Configuration
20+
PropR.Eval
21+
PropR.Plugin
22+
PropR.Repair
23+
PropR.Check
24+
PropR.Traversals
25+
PropR.Types
26+
PropR.Diff
27+
PropR.Util
28+
PropR.Search
29+
PropR.Search.PseudoGenetic
30+
PropR.Search.Genetic
31+
PropR.Search.Random
32+
PropR.Search.Exhaustive
3433
PropR.Packages
35-
other-modules: PropR.Configuration.Configure,
36-
PropR.Configuration.Types,
37-
PropR.Configuration.Materializeable,
38-
PropR.Search.Class,
39-
PropR.Search.Genetic.Configuration,
40-
PropR.Search.Genetic.GenMonad,
41-
PropR.Search.Genetic.Search,
42-
PropR.Search.Genetic.Types,
34+
other-modules: PropR.Configuration.Configure
35+
PropR.Configuration.Types
36+
PropR.Configuration.Materializeable
37+
PropR.Search.Class
38+
PropR.Search.Genetic.Configuration
39+
PropR.Search.Genetic.GenMonad
40+
PropR.Search.Genetic.Search
41+
PropR.Search.Genetic.Types
4342
PropR.Search.Genetic.Utils
44-
PropR.Search.PseudoGenetic.Configuration,
45-
PropR.Search.PseudoGenetic.Search,
46-
PropR.Search.Random.Configuration,
47-
PropR.Search.Random.Search,
48-
PropR.Search.Exhaustive.Configuration,
43+
PropR.Search.PseudoGenetic.Configuration
44+
PropR.Search.PseudoGenetic.Search
45+
PropR.Search.Random.Configuration
46+
PropR.Search.Random.Search
47+
PropR.Search.Exhaustive.Configuration
4948
PropR.Search.Exhaustive.Search
49+
5050
build-depends: base >= 4 && < 5,
51-
ghc >= 8 && < 9,
52-
ghc-boot >= 8 && < 9,
53-
ghc-boot-th >= 8 && < 9,
54-
ghc-paths >= 0.1 && < 0.2,
55-
ghc-prim >= 0.6 && < 0.7,
56-
hpc >= 0.6 && < 0.7,
57-
time >= 1.9 && < 1.10,
58-
directory >= 1.3 && < 1.4,
59-
filepath >= 1.4 && < 1.5,
60-
process >= 1.6 && < 1.7,
61-
containers >= 0.6 && < 0.7,
62-
unix >= 2.7.2 && < 2.8,
63-
lens >= 5.0 && < 5.1,
64-
comonad >= 5.0 && < 5.1,
65-
mwc-random >= 0.15 && < 0.16,
66-
vector >= 0.12 && < 0.13,
67-
async >= 2.2 && < 2.3,
68-
random >= 1.2 && < 1.3,
69-
transformers >= 0.5 && < 0.6,
70-
monad-par >= 0.3 && < 0.4,
71-
monad-par-extras >= 0.3 && < 0.4,
72-
deepseq >= 1.4 && < 1.5,
73-
data-default >= 0.7 && < 0.8,
74-
vector >= 0.12 && < 0.13,
75-
deriving-aeson >= 0.2 && < 0.3,
76-
bytestring >= 0.10 && < 0.11,
77-
splitmix >= 0.1 && < 0.2,
78-
Cabal >= 3.4 && < 3.5,
79-
aeson >= 1.5 && < 1.6
51+
ghc >= 9,
52+
ghc-boot >= 9,
53+
ghc-paths >= 0.1,
54+
ghc-prim >= 0.10,
55+
bytestring >= 0.11,
56+
Cabal >= 3.8,
57+
hpc >= 0.6,
58+
time >= 1.12,
59+
directory >= 1.3,
60+
filepath >= 1.4,
61+
process >= 1.6,
62+
containers >= 0.6,
63+
unix >= 2.8,
64+
lens >= 5,
65+
comonad >= 5.0,
66+
mwc-random >= 0.15,
67+
vector >= 0.13,
68+
async >= 2.2,
69+
random >= 1.2,
70+
transformers >= 0.5,
71+
deepseq >= 1.4,
72+
data-default >= 0.7,
73+
deriving-aeson >= 0.2,
74+
splitmix >= 0.1,
75+
aeson >= 2.1
8076

8177
executable propr
82-
default-language: Haskell2010
78+
default-language: GHC2021
8379
main-is: src/Main.hs
8480
ghc-options: -threaded -O2
8581
other-modules: Paths_PropR
8682
build-depends: base >= 4 && < 5,
87-
containers >= 0.6 && < 0.7,
88-
directory >= 1.3 && < 1.4,
89-
ghc >= 8 && < 9,
90-
time >= 1.9 && < 1.10,
91-
data-default >= 0.7 && < 0.8,
92-
optparse-applicative >= 0.16 && < 0.17,
93-
bytestring >= 0.10 && < 0.11,
94-
aeson >= 1.5 && < 1.6,
95-
random >= 1.2 && < 1.3,
83+
optparse-applicative >= 0.17 && < 0.18,
84+
-- these are all specified in the library itself
85+
containers,
86+
directory,
87+
ghc,
88+
time,
89+
data-default,
90+
bytestring,
91+
aeson,
92+
random,
9693
PropR
9794

9895

99-
test-suite test
100-
default-language: Haskell2010
101-
type: exitcode-stdio-1.0
96+
common testing
97+
default-language: GHC2021
10298
hs-source-dirs: tests/
10399
ghc-options: -threaded -O2
104-
main-is: Tests.hs
105100
other-modules: TestUtils
106101
build-depends: base >= 4 && < 5,
107-
tasty >= 1.4 && < 1.5,
102+
tasty >= 1.4,
108103
tasty-hunit >= 0.10,
109104
tasty-quickcheck >= 0.10,
110105
tasty-expected-failure >= 0.12,
111-
containers >= 0.6 && < 0.7,
112-
ghc >= 8 && < 9,
113-
hpc >= 0.6 && < 0.7,
114-
data-default >= 0.7 && < 0.8,
115-
directory >= 1.3 && < 1.4,
106+
containers,
107+
ghc,
108+
hpc,
109+
data-default,
110+
directory,
116111
PropR,
117112
-- packages used in repair:
118113
QuickCheck
119114

115+
test-suite test
116+
import: testing
117+
type: exitcode-stdio-1.0
118+
main-is: Tests.hs
119+
120120
test-suite slow-test
121-
default-language: Haskell2010
121+
import: testing
122122
type: exitcode-stdio-1.0
123-
hs-source-dirs: tests/
124-
ghc-options: -threaded -O2
125123
main-is: SlowTests.hs
126-
other-modules: TestUtils
127-
build-depends: base >= 4 && < 5,
128-
tasty >= 1.4,
129-
tasty-hunit >= 0.10,
130-
tasty-quickcheck >= 0.10,
131-
tasty-expected-failure >= 0.12,
132-
containers >= 0.6 && < 0.7,
133-
ghc >= 8 && < 9,
134-
hpc >= 0.6 && < 0.7,
135-
data-default >= 0.7 && < 0.8,
136-
directory >= 1.3 && < 1.4,
137-
PropR,
138-
-- packages used in repair:
139-
QuickCheck
140124

141125
benchmark benchmark
142-
default-language: Haskell2010
126+
import: testing
143127
type: exitcode-stdio-1.0
144-
hs-source-dirs: tests/
145-
ghc-options: -threaded -O2
146128
main-is: Benchmarks.hs
147-
other-modules: TestUtils
148-
build-depends: base >= 4 && < 5,
149-
tasty >= 1.4,
150-
tasty-hunit >= 0.10,
151-
tasty-quickcheck >= 0.10,
152-
tasty-expected-failure >= 0.12,
153-
containers >= 0.6 && < 0.7,
154-
ghc >= 8 && < 9,
155-
hpc >= 0.6 && < 0.7,
156-
data-default >= 0.7 && < 0.8,
157-
directory >= 1.3 && < 1.4,
158-
PropR,
159-
-- packages used in repair:
160-
QuickCheck

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ These are the versions we currently use - older versions might work too, please
3535

3636
## Usage
3737
-----
38-
This program requires version `3.4` or higher of `cabal`, and version `8.10` of `ghc`.
38+
This program requires version `3.4` or higher of `cabal`, and version `9.6` or `9.8` of `ghc`.
3939
A complete environment required to run (minus the `QuickCheck`)
4040
is defined in `shell.nix`, and can be activated using `nix-shell`, if installed.
4141

check-helpers/check-helpers.cabal

+5
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ library
1111
ghc-options: -O2
1212
hs-source-dirs: ./
1313
exposed-modules: Check.Helpers
14+
reexported-modules: Test.QuickCheck,
15+
Test.QuickCheck.Random,
16+
Test.Tasty,
17+
Test.Tasty.Runners,
18+
Test.Tasty.Ingredients
1419
build-depends: base >= 4 && < 5,
1520
tasty >= 1.4 && < 1.5,
1621
containers >= 0.6 && < 0.7,

src/Main.hs

-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ import qualified Data.Set as Set
1818
import Data.Time.LocalTime (utc)
1919
import Data.Version (showVersion)
2020
import GHC (HsExpr (HsLet), NoExtField (..))
21-
import GhcPlugins (noLoc)
2221
import Options.Applicative
2322
import Options.Applicative.Types (readerAsk)
2423
import qualified Paths_PropR as PE (version)

0 commit comments

Comments
 (0)