I looked into every single thread about this error message and tried everything, but it keeps disrupting the compiler. My Code:
check2 :: Slot -> Slot -> Bool
check2 c1 c2 = if (getTime c1 == getTime c2) | (getSubject c1 == getSubject c2)
then False
else True
It throws a nice error: parse error on input ‘|’
Clarification: all tabs are 8-spaces As you may guess, the method is part of a more larger method and was in a where clause originally. If I put it in the where clause, the parse error is on a different place, which is highly frustrating.
Aucun commentaire:
Enregistrer un commentaire