|
[ ghc-Bugs-1184340 ] Incorrect Type Inference?: msg#00086lang.haskell.glasgow.bugs
Bugs item #1184340, was opened at 2005-04-16 17:36 Message generated for change (Comment added) made by simonmar You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1184340&group_id=8032 Category: GHCi Group: 6.4 >Status: Closed >Resolution: Invalid Priority: 5 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: Incorrect Type Inference? Initial Comment: If the function func1 = \x -> map (*x) is saved into a file, and then imported to ghci (v6.4, windows), the type becomes Integer -> [Integer] -> [Integer] However, if I do :t \x -> map (*x) the result is: \x -> map (*x) :: (Num a) => a -> [a] -> [a] which seems correct. ---------------------------------------------------------------------- >Comment By: Simon Marlow (simonmar) Date: 2005-04-19 13:17 Message: Logged In: YES user_id=48280 The monomorphism restriction applies to definitions in source files, but not to expressions supplied as the argument to :type in GHCi. Not a bug, sorry. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1184340&group_id=8032
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | RE: ghc's hPutBuf doesn't obey the buffering mode, Simon Marlow |
|---|---|
| Next by Date: | [ ghc-Bugs-1184356 ] amd64 architecture not correctly detected, SourceForge.net |
| Previous by Thread: | [ ghc-Bugs-1184340 ] Incorrect Type Inference?, SourceForge.net |
| Next by Thread: | [ ghc-Bugs-1184356 ] amd64 architecture not correctly detected, SourceForge.net |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |