X-Git-Url: https://git.njae.me.uk/?a=blobdiff_plain;f=src%2Fadvent21%2Fadvent21parallel.hs;h=3ec87ff338581435d194b4459897d78967e73e42;hb=0c7f1b478186169e9ef06ceb669a0c5f489a4849;hp=cd0b898b9b4843ef9af29b354c2864c09115aa20;hpb=6c841469511fafa9c6108244023536b1a124ff24;p=advent-of-code-17.git diff --git a/src/advent21/advent21parallel.hs b/src/advent21/advent21parallel.hs index cd0b898..3ec87ff 100644 --- a/src/advent21/advent21parallel.hs +++ b/src/advent21/advent21parallel.hs @@ -12,10 +12,8 @@ import Text.Megaparsec hiding (State) import qualified Text.Megaparsec.Lexer as L import Text.Megaparsec.Text (Parser) import qualified Control.Applicative as CA --- import qualified Data.Functor as F import qualified Data.Map.Strict as M -import Data.Map.Strict ((!)) import Data.List @@ -110,7 +108,7 @@ explodeGrid :: Grid -> ExplodedGrid explodeGrid g = if (rm + 1) `rem` 2 == 0 then explodeGrid' 2 g else explodeGrid' 3 g - where (rm, cm) = bounds g + where (rm, _cm) = bounds g explodeGrid' :: Int -> Grid -> ExplodedGrid explodeGrid' n g = M.fromList [((bigR, bigC), subGrid n g bigR bigC) | bigR <- [0..bigRm], bigC <- [0..bigCm]] @@ -172,8 +170,6 @@ onlySpace = (char ' ') <|> (char '\t') sc :: Parser () sc = L.space (skipSome onlySpace) CA.empty CA.empty -lexeme = L.lexeme sc - symbol = L.symbol sc rowSep = symbol "/" ruleJoin = symbol "=>"