Ticket #429 (closed bug: Duplicate)
when typing expression fails, don't try to Show it
|Reported by:||pimlott||Owned by:||nobody|
|Type of failure:||Difficulty:|
|Test Case:||Blocked By:|
Enter a ghci session, and run "print id": Prelude> print id Top level: No instance for (Show (IO ())) arising from use of `print' at Top level Probable fix: add an instance declaration for (Show (IO ())) In a 'do' expression: print it <interactive>:1:0: No instance for (Show (a -> a)) arising from use of `print' at <interactive>:1:0-4 Probable fix: add an instance declaration for (Show (a -> a)) In the definition of `it': it = print id It would be nice to make the first error go away. It looks as if, when typing "print id" fails, ghci nonetheless goes ahead and tries to type "let it = print id; print it", or something. This just creates useless noise.
Note: See TracTickets for help on using tickets.