Parse a string using the Read
instance.
Succeeds if there is exactly one valid result.
A Left
value indicates a parse error.
>>>
readEither "123" :: Either String Int
Right 123
>>>
readEither "hello" :: Either String Int
Left "Prelude.read: no parse"
Since: base-4.6.0.0