<div dir="ltr"><br><br>On Friday, May 27, 2016 at 1:38:36 PM UTC-5, David Kraeutmann wrote:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">GHCi enables -XExtendedDefaultRules, which cause read "2" to default to ().
<br></blockquote><div><br></div><div>Ah - thank you very much! Indeed it is a consequence of the ExtendedDefaultRules option:</div><div><br></div><div><div><font face="courier new, monospace">GHCi, version 7.10.2: http://www.haskell.org/ghc/  :? for help</font></div><div><font face="courier new, monospace">Prelude> :set -XNoExtendedDefaultRules</font></div><div><font face="courier new, monospace">Prelude> read "2"</font></div><div><font face="courier new, monospace"><br></font></div><div><font face="courier new, monospace"><interactive>:3:1:</font></div><div><font face="courier new, monospace">    No instance for (Read a0) arising from a use of ‘it’</font></div></div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">On 5/27/2016 8:28 PM, Erik Rantapaa wrote:
<br>> Hi fellow Haskellers!
<br>>
<br>> If I bring up ghci and evaluate `read 2` I get the error "Prelude.read: no
<br>> parse"
<br>>
<br>> GHCi, version 7.10.2: <a href="http://www.haskell.org/ghc/" target="_blank" rel="nofollow" onmousedown="this.href='http://www.google.com/url?q\x3dhttp%3A%2F%2Fwww.haskell.org%2Fghc%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHb7L_g-MYtgGdtI_q9yk2_p594pw';return true;" onclick="this.href='http://www.google.com/url?q\x3dhttp%3A%2F%2Fwww.haskell.org%2Fghc%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHb7L_g-MYtgGdtI_q9yk2_p594pw';return true;">http://www.haskell.org/ghc/</a>  :? for help
<br>> Prelude> read "2"
<br>> *** Exception: Prelude.read: no parse
<br>>
<br>> Exactly how is this message coming about? I understand that `read` needs a
<br>> return type in order to determine which type class instance to run. So, in
<br>> this case, which type is `read` being asked to return?
<br>>
<br>> Thanks,
<br>> Erik
<br>>
<br>>
<br>>
<br>>
<br>> ______________________________<wbr>_________________
<br>> Haskell-Cafe mailing list
<br>> <a href="javascript:" target="_blank" gdf-obfuscated-mailto="vqZn9frlAQAJ" rel="nofollow" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">Haskel...@haskell.org</a>
<br>> <a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe" target="_blank" rel="nofollow" onmousedown="this.href='http://www.google.com/url?q\x3dhttp%3A%2F%2Fmail.haskell.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Fhaskell-cafe\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNH7sFgl7KfuDcDlaGGG3ip3kRaoIA';return true;" onclick="this.href='http://www.google.com/url?q\x3dhttp%3A%2F%2Fmail.haskell.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Fhaskell-cafe\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNH7sFgl7KfuDcDlaGGG3ip3kRaoIA';return true;">http://mail.haskell.org/cgi-<wbr>bin/mailman/listinfo/haskell-<wbr>cafe</a>
<br>>
<br>
<br>
<br></blockquote></div>