aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralexwl <alexey.a.kiryushin@gmail.com>2019-03-14 22:40:27 +0300
committeralexwl <alexey.a.kiryushin@gmail.com>2019-03-14 22:40:27 +0300
commitcac568f01609bf224c0e26ec62880bf7dbb58a07 (patch)
tree4a049555416709e016e2dd8615e6422aa1cbd687
parent78f46be07c7d063c9d957bfe4d580fcbeb28786f (diff)
Add support for GHC 8.6.4
-rw-r--r--README.md10
-rw-r--r--app/Indexer.hs5
-rw-r--r--app/Store.hs5
-rw-r--r--stack-8.6.3.yaml8
-rw-r--r--stack.yaml2
-rw-r--r--test/Main.hs4
-rw-r--r--test/test-package/stack-8.6.3.yaml1
-rw-r--r--test/test-package/stack.yaml2
8 files changed, 31 insertions, 6 deletions
diff --git a/README.md b/README.md
index 9f84f06..cffa428 100644
--- a/README.md
+++ b/README.md
@@ -46,14 +46,20 @@ cd haskell-code-explorer
To build Haskell Code Explorer Stack ([https://docs.haskellstack.org/en/stable/README/](https://docs.haskellstack.org/en/stable/README/)) is needed.
-At the moment Haskell Code Explorer supports GHC 8.6.3, GHC 8.4.4, GHC 8.4.3, GHC 8.2.2, and 8.0.2.
+At the moment Haskell Code Explorer supports GHC 8.6.4, GHC 8.6.3, GHC 8.4.4, GHC 8.4.3, GHC 8.2.2, and 8.0.2.
-For GHC 8.6.3:
+For GHC 8.6.4:
```bash
stack install
```
+For GHC 8.6.3:
+
+```bash
+stack --stack-yaml=stack-8.6.3.yaml install
+```
+
For GHC 8.4.4:
```bash
diff --git a/app/Indexer.hs b/app/Indexer.hs
index ee6a330..9560fad 100644
--- a/app/Indexer.hs
+++ b/app/Indexer.hs
@@ -73,7 +73,10 @@ data Compression
| NoCompression
deriving (Show, Eq)
-#if MIN_VERSION_GLASGOW_HASKELL(8,6,3,0)
+#if MIN_VERSION_GLASGOW_HASKELL(8,6,4,0)
+ghcVersion :: Version
+ghcVersion = Version {versionBranch = [8, 6, 4, 0], versionTags = []}
+#elif MIN_VERSION_GLASGOW_HASKELL(8,6,3,0)
ghcVersion :: Version
ghcVersion = Version {versionBranch = [8, 6, 3, 0], versionTags = []}
#elif MIN_VERSION_GLASGOW_HASKELL(8,4,4,0)
diff --git a/app/Store.hs b/app/Store.hs
index 956359d..495f190 100644
--- a/app/Store.hs
+++ b/app/Store.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE CPP #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TypeApplications #-}
{-# LANGUAGE TypeFamilyDependencies #-}
@@ -41,9 +42,13 @@ data Location = Location
} deriving (Show, Eq, Ord, Generic, NFData)
instance Serialize Location
+
+#if MIN_VERSION_cereal(0,5,8)
+#else
instance Serialize BSS.ShortByteString where
put = put . BSS.fromShort
get = BSS.toShort <$> get
+#endif
class StoreItem item where
toByteString :: item -> BS.ByteString
diff --git a/stack-8.6.3.yaml b/stack-8.6.3.yaml
new file mode 100644
index 0000000..a577156
--- /dev/null
+++ b/stack-8.6.3.yaml
@@ -0,0 +1,8 @@
+resolver: lts-13.0
+packages:
+- '.'
+- location: vendor/cabal-helper-0.8.1.2
+ extra-dep: true
+allow-newer: true
+extra-deps:
+ - cabal-plan-0.4.0.0
diff --git a/stack.yaml b/stack.yaml
index a577156..dc6a90a 100644
--- a/stack.yaml
+++ b/stack.yaml
@@ -1,4 +1,4 @@
-resolver: lts-13.0
+resolver: lts-13.12
packages:
- '.'
- location: vendor/cabal-helper-0.8.1.2
diff --git a/test/Main.hs b/test/Main.hs
index 3ed32a4..e4bd4f0 100644
--- a/test/Main.hs
+++ b/test/Main.hs
@@ -155,8 +155,10 @@ moduleInfoSpec modInfo =
HCE.idOccMap (modInfo :: HCE.ModuleInfo) `shouldBe` testIdOccMap
stackYamlArg :: [String]
-#if MIN_VERSION_GLASGOW_HASKELL(8,6,1,0)
+#if MIN_VERSION_GLASGOW_HASKELL(8,6,4,0)
stackYamlArg = []
+#elif MIN_VERSION_GLASGOW_HASKELL(8,6,1,0)
+stackYamlArg = ["--stack-yaml=stack-8.6.3.yaml"]
#elif MIN_VERSION_GLASGOW_HASKELL(8,4,4,0)
stackYamlArg = ["--stack-yaml=stack-8.4.4.yaml"]
#elif MIN_VERSION_GLASGOW_HASKELL(8,4,3,0)
diff --git a/test/test-package/stack-8.6.3.yaml b/test/test-package/stack-8.6.3.yaml
new file mode 100644
index 0000000..6dcd7f8
--- /dev/null
+++ b/test/test-package/stack-8.6.3.yaml
@@ -0,0 +1 @@
+resolver: lts-13.0
diff --git a/test/test-package/stack.yaml b/test/test-package/stack.yaml
index 4e996a7..88f5e2c 100644
--- a/test/test-package/stack.yaml
+++ b/test/test-package/stack.yaml
@@ -1 +1 @@
-resolver: nightly-2018-12-21
+resolver: lts-13.12