<div dir="ltr">Hi,<div><br></div><div>Part of what you would like is already there. If you run ghci with -Wall, you will get warnings about defaulting polymorphic expressions.</div><div><br></div><div>```</div><div><div>Prelude> 1</div><div><br></div><div><interactive>:2:1: Warning:</div><div> Defaulting the following constraint(s) to type ‘Integer’</div><div> (Num a0) arising from a use of ‘it’ at <interactive>:2:1</div><div> (Show a0) arising from a use of ‘print’ at <interactive>:2:1</div><div> In the first argument of ‘print’, namely ‘it’</div><div> In a stmt of an interactive GHCi command: print it</div><div>1</div><div>Prelude></div></div><div>```</div><div><br></div><div>--trevor</div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Apr 28, 2016 at 8:05 AM Johannes Waldmann <<a href="mailto:johannes.waldmann@htwk-leipzig.de">johannes.waldmann@htwk-leipzig.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
> If you ask GHCi to *evaluate* a polymorphic expression, then it will ...<br>
<br>
Sure, I understand the motivation for defaulting,<br>
and I am not suggesting to change anything there.<br>
<br>
What I am saying is that I see no way to have ghci show<br>
* the defaulted type,<br>
* or the even the fact that defaulting did happen.<br>
<br>
- J.<br>
<br>
_______________________________________________<br>
ghc-devs mailing list<br>
<a href="mailto:ghc-devs@haskell.org" target="_blank">ghc-devs@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
</blockquote></div>