diff --git a/.github/workflows/cabal.yml b/.github/workflows/cabal.yml index 03a619b..1eedef0 100644 --- a/.github/workflows/cabal.yml +++ b/.github/workflows/cabal.yml @@ -10,9 +10,12 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - cabal: ["3.6"] + cabal: ["3.10.3.0"] ghc: - - "9.2.5" + - "9.2.8" + - "9.4.7" + - "9.6.3" + - "9.8.1" steps: - uses: actions/checkout@v3 @@ -25,7 +28,7 @@ jobs: version: "4.8.7" - name: Setup GHC and cabal-install - uses: haskell/actions/setup@v2 + uses: haskell-actions/setup@v2 with: ghc-version: ${{ matrix.ghc }} cabal-version: ${{ matrix.cabal }} @@ -37,7 +40,7 @@ jobs: ~/.cabal/packages ~/.cabal/store dist-newstyle - key: ${{ runner.os }}-${{ matrix.ghc }}-cabal-${{ hashFiles('**/*.cabal', '**/cabal.project', '**/cabal.project.freeze') }} + key: ${{ runner.os }}-${{ matrix.ghc }}-cabal-${{ hashFiles('**/*.cabal') }} - name: Update package list run: cabal update diff --git a/.github/workflows/stack.yml b/.github/workflows/stack.yml index 2d8fddc..8f2208d 100644 --- a/.github/workflows/stack.yml +++ b/.github/workflows/stack.yml @@ -10,10 +10,12 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - cabal: ["3.6"] + cabal: ["3.10.3.0"] ghc: - - "9.2.5" - - "9.0.2" + - "9.2.8" + - "9.4.7" + - "9.6.3" + - "9.8.1" steps: - uses: actions/checkout@v3 @@ -26,7 +28,7 @@ jobs: version: "4.8.7" - name: Setup Stack - uses: haskell/actions/setup@v2 + uses: haskell-actions/setup@v2 with: ghc-version: ${{ matrix.ghc }} cabal-version: ${{ matrix.cabal }} diff --git a/README.md b/README.md index 37d60d8..45a2b24 100644 --- a/README.md +++ b/README.md @@ -11,14 +11,18 @@ This repo demonstrates how to use [LiquidHaskell](https://github.com/ucsd-progsy - how to point `stack` at the relevant LH repositories on **github** -[stack/stack-9.0.2.yaml](stack/stack-9.0.2.yaml) shows +[stack/stack-*.yaml](stack/) shows - how to point `stack` at the relevant LH packages on **hackage** -[cabal.project](cabal.project) shows +[cabal.project.github](cabal.project.github) shows - how to point `cabal` to the relevant LH repositories on **github** -- only works with ghc-9.2.5 +- only works with ghc-9.8.1 + +No `cabal.project` file is needed for the releases of `liquidhaskell` in hackage. +`cabal-install` should pick the appropriate version for each compiler (supported GHCs: +9.2.8, 9.4.7, 9.6.3, 9.8.1) ## GHCi Integration diff --git a/cabal.project b/cabal.project.github similarity index 100% rename from cabal.project rename to cabal.project.github diff --git a/lh-plugin-demo.cabal b/lh-plugin-demo.cabal index 681efe4..d49f5b2 100644 --- a/lh-plugin-demo.cabal +++ b/lh-plugin-demo.cabal @@ -22,15 +22,8 @@ library build-depends: liquid-prelude, liquid-vector, - liquidhaskell - if impl(ghc >= 9.2) - build-depends: + liquidhaskell, base, containers, vector - else - build-depends: - liquid-base, - liquid-containers default-language: Haskell2010 - -- ghc-options: -fplugin=LiquidHaskell diff --git a/stack/stack-9.0.2.yaml b/stack/stack-9.0.2.yaml deleted file mode 100644 index 094fc3e..0000000 --- a/stack/stack-9.0.2.yaml +++ /dev/null @@ -1,18 +0,0 @@ -resolver: lts-19.33 -packages: - - .. -extra-deps: - - hashable-1.3.5.0 - - rest-rewrite-0.4.1 - - smtlib-backends-0.3 - - smtlib-backends-process-0.3 - - liquidhaskell-0.9.0.2.1 - - liquid-base-4.15.1.0 - - liquid-containers-0.6.4.1 - - liquid-ghc-prim-0.7.0.1 - - liquid-prelude-0.9.0.2 - - liquid-vector-0.12.3.1 - - liquid-fixpoint-0.9.0.2.1 - -nix: - packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.2.5.yaml b/stack/stack-9.2.5.yaml deleted file mode 100644 index cd27d27..0000000 --- a/stack/stack-9.2.5.yaml +++ /dev/null @@ -1,20 +0,0 @@ -resolver: lts-20.1 -packages: - - .. -extra-deps: - - hashable-1.3.5.0 - - rest-rewrite-0.4.1 - - smtlib-backends-0.3 - - smtlib-backends-process-0.3 - - git: https://github.com/ucsd-progsys/liquidhaskell - commit: fc4a89b91fad8b7a02b72901381d4358a470e230 - subdirs: - - . - - liquidhaskell-boot - - liquid-prelude - - liquid-vector - - git: https://github.com/ucsd-progsys/liquid-fixpoint - commit: eb339f9abdf073f8d9f0c446c309006fdf49ed42 - -nix: - packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.2.8.yaml b/stack/stack-9.2.8.yaml new file mode 100644 index 0000000..1a39380 --- /dev/null +++ b/stack/stack-9.2.8.yaml @@ -0,0 +1,15 @@ +resolver: lts-20.26 +packages: + - .. +extra-deps: + - rest-rewrite-0.4.3 + - smtlib-backends-0.3 + - smtlib-backends-process-0.3 + - liquidhaskell-0.9.2.8.0 + - liquidhaskell-boot-0.9.2.8.0 + - liquid-fixpoint-0.9.2.5 + - liquid-prelude-0.9.2.8.1 + - liquid-vector-0.12.3.1.2 + +nix: + packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.2.8.yaml.lock b/stack/stack-9.2.8.yaml.lock new file mode 100644 index 0000000..1905abb --- /dev/null +++ b/stack/stack-9.2.8.yaml.lock @@ -0,0 +1,68 @@ +# This file was autogenerated by Stack. +# You should not edit this file by hand. +# For more information, please see the documentation at: +# https://docs.haskellstack.org/en/stable/lock_files + +packages: +- completed: + hackage: rest-rewrite-0.4.1@sha256:1254960c0a595cf4c9d5a3b986f42644407c63c74578d75b3568a6a12e5143f0,3886 + pantry-tree: + sha256: 17b4e99420cc1929e2b7d29558a0f909d6fcabd263fbc590dbf2585f893f5a6e + size: 4018 + original: + hackage: rest-rewrite-0.4.1 +- completed: + hackage: smtlib-backends-0.3@sha256:a947aead99f6a314833bddca9b502d5faea8d3bd2fc76ffb53c34d5c5b7557bc,1211 + pantry-tree: + sha256: 97b88a647ac996808a93b2eab62e9e8574d9b9a451ee37a9103e209b63be012d + size: 275 + original: + hackage: smtlib-backends-0.3 +- completed: + hackage: smtlib-backends-process-0.3@sha256:caf131d3d6f6825e3a3182713130a8e14d0bd6530eeda643e8a511b546ff1a26,1676 + pantry-tree: + sha256: 7147fef29b4270275168a285fc0c68784329d1276ab9e44e9a45f8d79b526220 + size: 461 + original: + hackage: smtlib-backends-process-0.3 +- completed: + hackage: liquidhaskell-0.9.2.8.0@sha256:0047b9c51aee1738f2b8aefd42c3d75a78f04a8c38ffddf182619589db410eb9,3475 + pantry-tree: + sha256: c52b7a1bee8310cd7adabd25a9c9a60eeb1d1d8b8812f5e8de6dd840e21ea163 + size: 3291 + original: + hackage: liquidhaskell-0.9.2.8.0 +- completed: + hackage: liquidhaskell-boot-0.9.2.8.0@sha256:b50ea67b051e0914cf7279942a8168cfdc6c9bf9eb4699a6ca6367142ad710ab,9835 + pantry-tree: + sha256: d0b1eca3c824fbea5fa758f92d5825c8037f5d46172223af20c6652fd1c8f0a2 + size: 7768 + original: + hackage: liquidhaskell-boot-0.9.2.8.0 +- completed: + hackage: liquid-fixpoint-0.9.2.5@sha256:4fa5c333c1238c776002dbb4840270478789a73eae0a5712a5d859e4bbd8ece5,9406 + pantry-tree: + sha256: eed85537200105f10ec9d2c7e2a91a5693b9a7008222759c6e6401e546eb87f5 + size: 15988 + original: + hackage: liquid-fixpoint-0.9.2.5 +- completed: + hackage: liquid-prelude-0.9.2.8.1@sha256:f91d3a6dfc913f9ea1665af4ad92cc0e32d27d981244552129b083d169b1eb2e,1481 + pantry-tree: + sha256: 83ff7d4ed1411fbe597c1cfe27989e19352731b511bbdc72ed1e262f13ca93ca + size: 882 + original: + hackage: liquid-prelude-0.9.2.8.1 +- completed: + hackage: liquid-vector-0.12.3.1.2@sha256:940268dec6a7902408b85377c3abca72831d119ad89d1e3f870374db0ab0eb4a,1105 + pantry-tree: + sha256: f0be404b64d9baa7c2b657885cae555f23ad713633aa9ec6fef5e2e9582e5bb4 + size: 231 + original: + hackage: liquid-vector-0.12.3.1.2 +snapshots: +- completed: + sha256: 5a59b2a405b3aba3c00188453be172b85893cab8ebc352b1ef58b0eae5d248a2 + size: 650475 + url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/20/26.yaml + original: lts-20.26 diff --git a/stack/stack-9.4.7.yaml b/stack/stack-9.4.7.yaml new file mode 100644 index 0000000..33b5ea7 --- /dev/null +++ b/stack/stack-9.4.7.yaml @@ -0,0 +1,15 @@ +resolver: lts-21.21 +packages: + - .. +extra-deps: + - rest-rewrite-0.4.3 + - smtlib-backends-0.3 + - smtlib-backends-process-0.3 + - liquidhaskell-0.9.4.7.0 + - liquidhaskell-boot-0.9.4.7.0 + - liquid-fixpoint-0.9.4.7 + - liquid-prelude-0.9.2.8.1 + - liquid-vector-0.12.3.1.2 + +nix: + packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.4.7.yaml.lock b/stack/stack-9.4.7.yaml.lock new file mode 100644 index 0000000..3e0d792 --- /dev/null +++ b/stack/stack-9.4.7.yaml.lock @@ -0,0 +1,68 @@ +# This file was autogenerated by Stack. +# You should not edit this file by hand. +# For more information, please see the documentation at: +# https://docs.haskellstack.org/en/stable/lock_files + +packages: +- completed: + hackage: rest-rewrite-0.4.1@sha256:1254960c0a595cf4c9d5a3b986f42644407c63c74578d75b3568a6a12e5143f0,3886 + pantry-tree: + sha256: 17b4e99420cc1929e2b7d29558a0f909d6fcabd263fbc590dbf2585f893f5a6e + size: 4018 + original: + hackage: rest-rewrite-0.4.1 +- completed: + hackage: smtlib-backends-0.3@sha256:a947aead99f6a314833bddca9b502d5faea8d3bd2fc76ffb53c34d5c5b7557bc,1211 + pantry-tree: + sha256: 97b88a647ac996808a93b2eab62e9e8574d9b9a451ee37a9103e209b63be012d + size: 275 + original: + hackage: smtlib-backends-0.3 +- completed: + hackage: smtlib-backends-process-0.3@sha256:caf131d3d6f6825e3a3182713130a8e14d0bd6530eeda643e8a511b546ff1a26,1676 + pantry-tree: + sha256: 7147fef29b4270275168a285fc0c68784329d1276ab9e44e9a45f8d79b526220 + size: 461 + original: + hackage: smtlib-backends-process-0.3 +- completed: + hackage: liquidhaskell-0.9.4.7.0@sha256:31866a28d6f3ef540ba8da75ec0459223b8ab445e0b6873075bd21b4ed76f6df,3559 + pantry-tree: + sha256: 4ce2d1af2f25a60139e772b3492a76c05b2b698a10c150fc8f9df68b042b6990 + size: 3367 + original: + hackage: liquidhaskell-0.9.4.7.0 +- completed: + hackage: liquidhaskell-boot-0.9.4.7.0@sha256:0de0c907e361d491454efc7e824ce72fb066ec8cc6b435766fc5beb9139ef22e,9835 + pantry-tree: + sha256: 7f3f00a09178d52e99650b0b0f43fc307de4cd5cb33c0096961c589b451bb16b + size: 7768 + original: + hackage: liquidhaskell-boot-0.9.4.7.0 +- completed: + hackage: liquid-fixpoint-0.9.4.7@sha256:63926bdb1f780c827c235e00358d0dfbe624d748670a694db6cd5c01c17ca55a,9478 + pantry-tree: + sha256: 03b2d32a0c0dc822e40865ecdfbd58baaa4954bb495c229c8db644b987cee9b9 + size: 16089 + original: + hackage: liquid-fixpoint-0.9.4.7 +- completed: + hackage: liquid-prelude-0.9.2.8.1@sha256:f91d3a6dfc913f9ea1665af4ad92cc0e32d27d981244552129b083d169b1eb2e,1481 + pantry-tree: + sha256: 83ff7d4ed1411fbe597c1cfe27989e19352731b511bbdc72ed1e262f13ca93ca + size: 882 + original: + hackage: liquid-prelude-0.9.2.8.1 +- completed: + hackage: liquid-vector-0.12.3.1.2@sha256:940268dec6a7902408b85377c3abca72831d119ad89d1e3f870374db0ab0eb4a,1105 + pantry-tree: + sha256: f0be404b64d9baa7c2b657885cae555f23ad713633aa9ec6fef5e2e9582e5bb4 + size: 231 + original: + hackage: liquid-vector-0.12.3.1.2 +snapshots: +- completed: + sha256: 7d4b649cf368f9076d8aa049aa44efe58950971d105892734e9957b2a26a2186 + size: 640060 + url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/21/21.yaml + original: lts-21.21 diff --git a/stack/stack-9.6.3.yaml b/stack/stack-9.6.3.yaml new file mode 100644 index 0000000..13c8b47 --- /dev/null +++ b/stack/stack-9.6.3.yaml @@ -0,0 +1,15 @@ +resolver: lts-22.6 +packages: + - .. +extra-deps: + - rest-rewrite-0.4.3 + - smtlib-backends-0.3 + - smtlib-backends-process-0.3 + - liquidhaskell-0.9.6.3.1 + - liquidhaskell-boot-0.9.6.3 + - liquid-fixpoint-0.9.6.3 + - liquid-prelude-0.9.2.8.1 + - liquid-vector-0.13.1.0.1 + +nix: + packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.6.3.yaml.lock b/stack/stack-9.6.3.yaml.lock new file mode 100644 index 0000000..7fb3da4 --- /dev/null +++ b/stack/stack-9.6.3.yaml.lock @@ -0,0 +1,68 @@ +# This file was autogenerated by Stack. +# You should not edit this file by hand. +# For more information, please see the documentation at: +# https://docs.haskellstack.org/en/stable/lock_files + +packages: +- completed: + hackage: rest-rewrite-0.4.1@sha256:1254960c0a595cf4c9d5a3b986f42644407c63c74578d75b3568a6a12e5143f0,3886 + pantry-tree: + sha256: 17b4e99420cc1929e2b7d29558a0f909d6fcabd263fbc590dbf2585f893f5a6e + size: 4018 + original: + hackage: rest-rewrite-0.4.1 +- completed: + hackage: smtlib-backends-0.3@sha256:a947aead99f6a314833bddca9b502d5faea8d3bd2fc76ffb53c34d5c5b7557bc,1211 + pantry-tree: + sha256: 97b88a647ac996808a93b2eab62e9e8574d9b9a451ee37a9103e209b63be012d + size: 275 + original: + hackage: smtlib-backends-0.3 +- completed: + hackage: smtlib-backends-process-0.3@sha256:caf131d3d6f6825e3a3182713130a8e14d0bd6530eeda643e8a511b546ff1a26,1676 + pantry-tree: + sha256: 7147fef29b4270275168a285fc0c68784329d1276ab9e44e9a45f8d79b526220 + size: 461 + original: + hackage: smtlib-backends-process-0.3 +- completed: + hackage: liquidhaskell-0.9.6.3.1@sha256:fb5309de42d2731e9bcfe37056e938f129b3b154f2aba5b864cc2b6871b07afc,3530 + pantry-tree: + sha256: cfeb7b080b455974e1ceb1bd7910fdb27bcacda4cc26b80baba5c720914861dc + size: 3369 + original: + hackage: liquidhaskell-0.9.6.3.1 +- completed: + hackage: liquidhaskell-boot-0.9.6.3@sha256:b700bb736bad616851b504b19e36597ca4e46fdc0f950f9a6130329989453aea,9834 + pantry-tree: + sha256: 80997559a500ff3d3fd889a0bb829d64707351eeab9262234376a63f242ec104 + size: 7768 + original: + hackage: liquidhaskell-boot-0.9.6.3 +- completed: + hackage: liquid-fixpoint-0.9.6.3@sha256:c368a22ba31705d8c0e6c02004d7bb56d0e8ae3f43def5988f3712690ab19348,9478 + pantry-tree: + sha256: 4a828ab82045ab3dc0c9039aad18d6e368694b34748cf18397ebb61a90349428 + size: 16089 + original: + hackage: liquid-fixpoint-0.9.6.3 +- completed: + hackage: liquid-prelude-0.9.2.8.1@sha256:f91d3a6dfc913f9ea1665af4ad92cc0e32d27d981244552129b083d169b1eb2e,1481 + pantry-tree: + sha256: 83ff7d4ed1411fbe597c1cfe27989e19352731b511bbdc72ed1e262f13ca93ca + size: 882 + original: + hackage: liquid-prelude-0.9.2.8.1 +- completed: + hackage: liquid-vector-0.13.1.0.1@sha256:2ad221ddf6e5fa109e6d4380b46dfa7f15e2ba2716be00a92e571c0063cdae70,1082 + pantry-tree: + sha256: d5d3d7d555ae8aae529b369d284fb859690f22ad37cc5ac6fef0b8402f47326a + size: 231 + original: + hackage: liquid-vector-0.13.1.0.1 +snapshots: +- completed: + sha256: 1b4c2669e26fa828451830ed4725e4d406acc25a1fa24fcc039465dd13d7a575 + size: 714100 + url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/22/6.yaml + original: lts-22.6 diff --git a/stack/stack-9.8.1.yaml b/stack/stack-9.8.1.yaml new file mode 100644 index 0000000..bf068ae --- /dev/null +++ b/stack/stack-9.8.1.yaml @@ -0,0 +1,17 @@ +resolver: nightly-2024-01-26 +packages: + - .. +extra-deps: + - rest-rewrite-0.4.3 + - smtlib-backends-0.3 + - smtlib-backends-process-0.3 + - store-0.7.18 + - store-core-0.4.4.7 + - liquidhaskell-0.9.8.1 + - liquidhaskell-boot-0.9.8.1 + - liquid-fixpoint-0.9.6.3 + - liquid-prelude-0.9.2.8.1 + - liquid-vector-0.13.1.0.1 + +nix: + packages: [cacert, git, hostname, z3] diff --git a/stack/stack-9.8.1.yaml.lock b/stack/stack-9.8.1.yaml.lock new file mode 100644 index 0000000..d41d9ca --- /dev/null +++ b/stack/stack-9.8.1.yaml.lock @@ -0,0 +1,82 @@ +# This file was autogenerated by Stack. +# You should not edit this file by hand. +# For more information, please see the documentation at: +# https://docs.haskellstack.org/en/stable/lock_files + +packages: +- completed: + hackage: rest-rewrite-0.4.3@sha256:915fb98b8c0a0f518c1a4b75bcf3ae27a3ebd5b10d60cc16a216c2fca2148ab0,3929 + pantry-tree: + sha256: 4de44fbeb7bd655caeafe605406c0bc5fe1788d9cf37cdac2f18b018ee4cf5e6 + size: 4075 + original: + hackage: rest-rewrite-0.4.3 +- completed: + hackage: smtlib-backends-0.3@sha256:a947aead99f6a314833bddca9b502d5faea8d3bd2fc76ffb53c34d5c5b7557bc,1211 + pantry-tree: + sha256: 97b88a647ac996808a93b2eab62e9e8574d9b9a451ee37a9103e209b63be012d + size: 275 + original: + hackage: smtlib-backends-0.3 +- completed: + hackage: smtlib-backends-process-0.3@sha256:caf131d3d6f6825e3a3182713130a8e14d0bd6530eeda643e8a511b546ff1a26,1676 + pantry-tree: + sha256: 7147fef29b4270275168a285fc0c68784329d1276ab9e44e9a45f8d79b526220 + size: 461 + original: + hackage: smtlib-backends-process-0.3 +- completed: + hackage: liquidhaskell-0.9.8.1@sha256:bcca22abc90d5ae4f6881453b50dbd683b23623e806b325145da0239fcf2d90d,3528 + pantry-tree: + sha256: 1b88896ce711f000af1130892c1addae4476953f69019c3524ea9768b3ea5f54 + size: 3369 + original: + hackage: liquidhaskell-0.9.8.1 +- completed: + hackage: liquidhaskell-boot-0.9.8.1@sha256:5b00e110d7217558e9dd6aad93c452bae4fd766df45919ef97e5758298eacce0,9792 + pantry-tree: + sha256: 123fbd934e4dcce949375eab37edbed62f01cbf5813c07bfe64903686cc743ed + size: 7809 + original: + hackage: liquidhaskell-boot-0.9.8.1 +- completed: + hackage: liquid-fixpoint-0.9.6.3@sha256:c368a22ba31705d8c0e6c02004d7bb56d0e8ae3f43def5988f3712690ab19348,9478 + pantry-tree: + sha256: 4a828ab82045ab3dc0c9039aad18d6e368694b34748cf18397ebb61a90349428 + size: 16089 + original: + hackage: liquid-fixpoint-0.9.6.3 +- completed: + hackage: liquid-prelude-0.9.2.8.1@sha256:f91d3a6dfc913f9ea1665af4ad92cc0e32d27d981244552129b083d169b1eb2e,1481 + pantry-tree: + sha256: 83ff7d4ed1411fbe597c1cfe27989e19352731b511bbdc72ed1e262f13ca93ca + size: 882 + original: + hackage: liquid-prelude-0.9.2.8.1 +- completed: + hackage: liquid-vector-0.13.1.0.1@sha256:2ad221ddf6e5fa109e6d4380b46dfa7f15e2ba2716be00a92e571c0063cdae70,1082 + pantry-tree: + sha256: d5d3d7d555ae8aae529b369d284fb859690f22ad37cc5ac6fef0b8402f47326a + size: 231 + original: + hackage: liquid-vector-0.13.1.0.1 +- completed: + hackage: store-0.7.18@sha256:af32079e0d31413b97a1759f8ad8555507857cd4ac4015e195fb5b0a27a3ce9f,8159 + pantry-tree: + sha256: 6e9fb2c1c59a9f2fb62abd0016841417b57b9a3e045088d48d65cc740cb1eeb9 + size: 1292 + original: + hackage: store-0.7.18 +- completed: + hackage: store-core-0.4.4.7@sha256:a2ea427ff0dde30252474dcb0641cb6928cb8a93cd5ee27d4c22adba8e729683,1489 + pantry-tree: + sha256: 67828df739695d14f81cd572a3085c76f65ac75f8417095afef8dfb2815f523e + size: 271 + original: + hackage: store-core-0.4.4.7 +snapshots: +- completed: + sha256: d6f7de20f9d885fee73539bad04c991452ee658a318a08bacc8bee1f2416fb85 + size: 556886 + url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/nightly/2024/1/14.yaml + original: nightly-2024-01-14