Ticket #472 (new feature request: None)
Supertyping of classes
| Reported by: | nobody | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | _|_ |
| Component: | Compiler (Type checker) | Version: | None |
| Keywords: | Cc: | merehap@… | |
| Operating System: | Unknown/Multiple | Architecture: | Unknown/Multiple |
| Type of failure: | None/Unknown | Difficulty: | Unknown |
| Test Case: | N/A | Blocked By: | |
| Blocking: | Related Tickets: |
Description (last modified by igloo) (diff)
see Supertyping Suggestion for Haskell
example:
class Num a <= Group a where (+) :: a -> a -> a negate :: a -> a
apart from multiple inheritance, it could work like this:
import Prelude hiding ((+),negate) import qualified Prelude ((+),negate) class Group a where (+) :: a -> a -> a negate :: a -> a instance Num a => Group a where (+) = (Prelude.+) negate = Prelude.negate
- coeus_at_gmx_de
Change History
Note: See
TracTickets for help on using
tickets.
