Skip to content

Commit 7708534

Browse files
committed
Expose all supported GHC versions (#2987)
Right now the only default GHC version gets exported by the flake. This means that libraries wanting to use the clash-compiler flake realistically can only support the default GHC version. If someone wants to use any of the other supported versions, that would work fine for clash-compiler, but it wouldn't trickle down to the libraries (which are stuck with the default ghc version). Graphs visualizing the issue: If you want to develop with the default version (ghc9101) ``` myprogram => ghc9101 |- clash-compiler => ghc9101 \- clash-protocols => ghc9101 |- clash-compiler => ghc9101 \- circuit-notation => ghc9101 \- clash-compiler => ghc9101 ``` With a non-default, but supported version (ghc964) ``` myprogram => ghc964 |- clash-compiler => ghc964 \- clash-protocols => ghc9101 |- clash-compiler => ghc9101 \- circuit-notation => ghc9101 \- clash-compiler => ghc9101 ```
1 parent 9ae791c commit 7708534

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

flake.nix

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@
8383
in
8484
assert pkgs.lib.asserts.assertOneOf "defaultGhcVersion" defaultGhcVersion ghcVersions;
8585
{
86+
# Export the variable so that other flakes can use it.
87+
ghcVersion = defaultGhcVersion;
88+
supportedGhcVersions = ghcVersions;
89+
8690
packages = {
8791
inherit (pkgs."clashPackages-${defaultGhcVersion}")
8892
clash-benchmark

0 commit comments

Comments
 (0)