Skip to content

Commit

Permalink
cleaner fix for unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
obfusk committed Aug 29, 2024
1 parent 5c11a23 commit 7fe8828
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion koneko.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ common deps

ghc-options: -Wall -fwarn-incomplete-uni-patterns -Werror
if impl(ghc >= 9.8)
ghc-options: -Wwarn=unused-imports -Wwarn=x-partial
ghc-options: -Wwarn=x-partial


library
Expand Down
2 changes: 1 addition & 1 deletion src/Koneko/Eval.hs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ import System.FilePath ((</>))
import System.IO (hPutStrLn, stderr)

#if !MIN_VERSION_GLASGOW_HASKELL(8, 8, 1, 0)
import Data.Monoid((<>))
import Data.Monoid ((<>))
#endif

import qualified Data.HashMap.Strict as H
Expand Down
4 changes: 3 additions & 1 deletion src/Koneko/Read.hs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ module Koneko.Read (read, read') where
import Control.Exception (throw)
import Control.Monad (replicateM)
import Data.Functor
import Data.List (foldl')
import Data.Maybe (fromJust) -- careful!
import Data.Text (Text)
import Prelude hiding (quot, read)
Expand All @@ -51,6 +50,9 @@ import Text.Megaparsec.Char
import Control.Monad.Fail (MonadFail)
import Data.List (init)
#endif
#if !MIN_VERSION_GLASGOW_HASKELL(9, 10, 1, 0)
import Data.List (foldl')
#endif

import qualified Data.Char as C
import qualified Data.Text as T
Expand Down
7 changes: 5 additions & 2 deletions src/Koneko/Test.hs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import GHC.IO.Handle (hDuplicate, hDuplicateTo)
import Control.Exception (bracket)
import Control.Monad (unless, when)
import Data.Char (isSpace)
import Data.Foldable (foldl', traverse_)
import Data.Foldable (traverse_)
import Data.Text (Text)
import Prelude hiding (exp, fail)
import System.Console.CmdArgs.Verbosity (Verbosity(..), getVerbosity)
Expand All @@ -35,7 +35,10 @@ import System.FilePath (takeExtension)
import System.IO (Handle)

#if !MIN_VERSION_GLASGOW_HASKELL(8, 8, 1, 0)
import Data.Monoid((<>))
import Data.Monoid ((<>))
#endif
#if !MIN_VERSION_GLASGOW_HASKELL(9, 10, 1, 0)
import Data.List (foldl')
#endif

import qualified Data.Text as T
Expand Down
2 changes: 1 addition & 1 deletion src/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import Data.Version (showVersion)
import System.Console.CmdArgs hiding (args)

#if !MIN_VERSION_GLASGOW_HASKELL(8, 8, 1, 0)
import Data.Monoid((<>))
import Data.Monoid ((<>))
#endif

import qualified Data.Text as T
Expand Down

0 comments on commit 7fe8828

Please sign in to comment.