[GHC] #10857: "ghci -XMonomorphismRestriction" doesn't turn on the monomorphism restriction
GHC
ghc-devs at haskell.org
Tue Sep 8 17:59:06 UTC 2015
#10857: "ghci -XMonomorphismRestriction" doesn't turn on the monomorphism
restriction
-------------------------------------+-------------------------------------
Reporter: rwbarton | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: GHCi | Version: 7.10.1
Keywords: newcomer | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Revisions: |
-------------------------------------+-------------------------------------
Compare
{{{
rwbarton at morphism:/tmp$ ghci-7.10.1 -XMonomorphismRestriction
GHCi, version 7.10.1: http://www.haskell.org/ghc/ :? for help
Prelude> let a = (+)
Prelude> :t a
a :: Num a => a -> a -> a
}}}
with
{{{
rwbarton at morphism:/tmp$ ghci-7.10.1
GHCi, version 7.10.1: http://www.haskell.org/ghc/ :? for help
Prelude> :set -XMonomorphismRestriction
Prelude> let a = (+)
Prelude> :t a
a :: Integer -> Integer -> Integer
}}}
Confusing!
This also occurred in 7.8.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10857>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list