Skip to content

Instantly share code, notes, and snippets.

@ironhouzi
Created June 22, 2018 16:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ironhouzi/64057101f29a90884e2d4e693e72e2b7 to your computer and use it in GitHub Desktop.
Save ironhouzi/64057101f29a90884e2d4e693e72e2b7 to your computer and use it in GitHub Desktop.
• Couldn't match expected type ‘[Letter]’
with actual type ‘[Letter] -> [(a, [Letter])]’
• Probable cause: ‘p’ is applied to too few arguments
In the first argument of ‘f’, namely ‘p’
In the first argument of ‘return’, namely ‘(f p)’
In the expression: return (f p)
• Relevant bindings include
p :: [Letter] -> [(a, [Letter])] (bound at src/Main.hs:49:28)
f :: [Letter] -> [(a -> b, [Letter])] (bound at src/Main.hs:49:13)
(<*>) :: Parser (a -> b) -> Parser a -> Parser b
(bound at src/Main.hs:49:16)
|
49 | (Parser f) <*> (Parser p) = return (f p)
| ^
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment