[GHC] #13069: hs-boot files permit default methods in type class
GHC
ghc-devs at haskell.org
Thu Jan 5 17:45:49 UTC 2017
#13069: hs-boot files permit default methods in type class
-------------------------------------+-------------------------------------
Reporter: ezyang | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler (Type | Version: 8.1
checker) | Keywords: backpack hs-
Resolution: | boot
Operating System: Unknown/Multiple | Architecture:
Type of failure: GHC accepts | Unknown/Multiple
invalid program | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by ezyang):
Actually, the bug is worse: the following A.hs-boot file is accepted by
GHC.
{{{
module A where
class C a where
f :: a -> a
f = True
}}}
This doesn't seem to be a soundness problem because what this actually
seems to translate into "there is a default method for f", so this code
never gets compiled / used for anything.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13069#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list