diff options
author | Vladislav Zavialov <vlad.z.4096@gmail.com> | 2023-01-17 09:41:03 +0300 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2023-01-17 16:33:41 -0500 |
commit | f4d50bafb7e14f76273aaf6f634815d5628ccc86 (patch) | |
tree | 52d5411dddea6b2992583fba6ad27c82b2af59db /hadrian/src | |
parent | 003b6d4460c08b15a45a6ff04bc77fcf8e3f6633 (diff) | |
download | haskell-f4d50bafb7e14f76273aaf6f634815d5628ccc86.tar.gz |
Hadrian: fix warnings (#22783)
This change fixes the following warnings when building Hadrian:
src/Hadrian/Expression.hs:38:10: warning: [-Wredundant-constraints]
src/Hadrian/Expression.hs:84:13: warning: [-Wtype-equality-requires-operators]
src/Hadrian/Expression.hs:84:21: warning: [-Wtype-equality-requires-operators]
src/Hadrian/Haskell/Cabal/Parse.hs:67:1: warning: [-Wunused-imports]
Diffstat (limited to 'hadrian/src')
-rw-r--r-- | hadrian/src/Hadrian/Expression.hs | 4 | ||||
-rw-r--r-- | hadrian/src/Hadrian/Haskell/Cabal/Parse.hs | 1 |
2 files changed, 1 insertions, 4 deletions
diff --git a/hadrian/src/Hadrian/Expression.hs b/hadrian/src/Hadrian/Expression.hs index 28a6c521b9..ad0f25ea5c 100644 --- a/hadrian/src/Hadrian/Expression.hs +++ b/hadrian/src/Hadrian/Expression.hs @@ -34,10 +34,8 @@ newtype Expr c b a = Expr (ReaderT (Target c b) Action a) instance Semigroup a => Semigroup (Expr c b a) where Expr x <> Expr y = Expr $ (<>) <$> x <*> y --- TODO: The 'Semigroup a' constraint will at some point become redundant. -instance (Semigroup a, Monoid a) => Monoid (Expr c b a) where +instance Monoid a => Monoid (Expr c b a) where mempty = pure mempty - mappend = (<>) -- | Expressions that compute a Boolean value. type Predicate c b = Expr c b Bool diff --git a/hadrian/src/Hadrian/Haskell/Cabal/Parse.hs b/hadrian/src/Hadrian/Haskell/Cabal/Parse.hs index a968975837..f7bdf2cab9 100644 --- a/hadrian/src/Hadrian/Haskell/Cabal/Parse.hs +++ b/hadrian/src/Hadrian/Haskell/Cabal/Parse.hs @@ -64,7 +64,6 @@ import Base import Builder import Context import Flavour -import Packages import Settings import Distribution.Simple.LocalBuildInfo import qualified Distribution.Simple.Register as C |