0
Hier ist mein Code:Haskell Liste Mustervergleich
newcell :: [Cell] -> [Cell]
newcell [Cell {cellPosition = cp, cellState = cs}]
= [Cell {cellPosition = cp, cellState = (nextCellState cs)}]
nextCellState
ist nur eine Funktion, aber es sagt nicht dem Muster entsprechen könnte.
src/StudentSources/LangtonsAnt.hs:141:1: Warning:
Pattern match(es) are non-exhaustive
In an equation for ‘newcell’:
Patterns not matched:
[]
(Cell _ _) : (_ : _)