Merge pull request #7 from erikd/master

Now builds with ghc 7.10 and 8.0
This commit is contained in:
Huw Campbell 2016-07-01 20:00:06 +10:00 committed by GitHub
commit a5398f7ec7
5 changed files with 8 additions and 4 deletions

View File

@ -54,7 +54,7 @@ and the tests run using:
./mafia test
```
Grenade is currently known to build with ghc 7.10. We are working on making it build with ghc 8.0.
Grenade is currently known to build with ghc 7.10 and 8.0.
Thanks

View File

@ -97,5 +97,5 @@ test-suite test
, hmatrix
, mtl
, text == 1.2.*
, QuickCheck == 2.7.*
, QuickCheck >= 2.7 && < 2.9
, quickcheck-instances == 0.3.*

2
mafia
View File

@ -118,4 +118,4 @@ case "$MODE" in
upgrade) shift; run_upgrade "$@" ;;
*) exec_mafia "$@"
esac
# Version: dbbe635d8f98be1815130f04465c155f414985bf
# Version: a1b39ee8ac1969ed2e891b9062d079be75863e99

View File

@ -25,7 +25,7 @@ train :: forall m i o hs. (Monad m, Head hs ~ i, Last hs ~ o, KnownShape i, Know
-> m (Network m hs)
train rate x0 target = fmap fst . go x0
where
go :: forall m' j js. (Monad m', Head js ~ j, Last js ~ o, KnownShape j, KnownShape o)
go :: forall m' j js. (Monad m', Head js ~ j, Last js ~ o, KnownShape j)
=> S' j -- ^ input vector
-> Network m' js -- ^ network to train
-> m' (Network m' js, S' j)

View File

@ -11,6 +11,10 @@
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
-- Ghc 8.0 gives a warning on `(+) _ _ = error ...` but ghc 7.10 fails to
-- compile without this default pattern.
{-# OPTIONS_GHC -fno-warn-overlapping-patterns #-}
module Grenade.Core.Shape (
Shape (..)
, S' (..)