]> Git — Sourcephile - majurity.git/blob - hjugement/tests/Types.hs
lib: impl: lint code
[majurity.git] / hjugement / tests / Types.hs
1 {-# LANGUAGE DeriveGeneric #-}
2 module Types where
3
4 import Data.Hashable
5 import GHC.Generics (Generic)
6 import Prelude
7
8 data G2 = No | Yes
9 deriving (Eq, Ord, Show, Bounded, Enum)
10
11 data G5 = Red | Pink | Orange | Yellow | Green
12 deriving (Eq, Ord, Show, Bounded, Enum)
13
14 data C1 = The
15 deriving (Eq, Ord, Show, Generic)
16 instance Hashable C1
17
18 data C2 = This | That
19 deriving (Eq, Ord, Show, Generic)
20 instance Hashable C2
21
22 data SchoolGrade
23 = ToReject
24 | Insufficient
25 | Acceptable
26 | Good
27 | VeryGood
28 | Perfect
29 deriving (Bounded, Enum, Eq, Ord, Show)
30
31 -- | Note that the grades 1, 2, 4, and 12 are absent.
32 data DanishSchoolGrade
33 = D0 -- ^ the completely unacceptable performance
34 | D3 -- ^ the very hesitant, very insufficient, and unsatisfactory performance
35 | D5 -- ^ the hesitant and not satisfactory performance
36 | D6 -- ^ the just acceptable performance
37 | D7 -- ^ the mediocre performance, slightly below average
38 | D8 -- ^ the average performance
39 | D9 -- ^ the good performance, a little above average
40 | D10 -- ^ the excellent but not particularly independent performance
41 | D11 -- ^ the independent and excellent performance
42 | D13 -- ^ the exceptionally independent and excellent performance
43 deriving (Bounded, Enum, Eq, Ord, Show)