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
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]]
sc :: Parser ()
sc = L.space (skipSome onlySpace) CA.empty CA.empty
-lexeme = L.lexeme sc
-
symbol = L.symbol sc
rowSep = symbol "/"
ruleJoin = symbol "=>"
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
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]]
sc :: Parser ()
sc = L.space (skipSome onlySpace) CA.empty CA.empty
-lexeme = L.lexeme sc
-
symbol = L.symbol sc
rowSep = symbol "/"
ruleJoin = symbol "=>"