{-# LANGUAGE DeriveDataTypeable #-} {- | Module : ./CSMOF/Sign.hs Description : CSMOF signature and sentences Copyright : (c) Daniel Calegari Universidad de la Republica, Uruguay 2013 License : GPLv2 or higher, see LICENSE.txt Maintainer : dcalegar@fing.edu.uy Stability : provisional Portability : portable -} module CSMOF.Sign where import CSMOF.As () import qualified Common.Lib.Rel as Rel import Common.Doc import Common.DocUtils import Common.Id import Data.Data import qualified Data.Map as Map import qualified Data.Set as Set data TypeKind = DataTypeKind | ClassKind deriving (Int -> TypeKind -> ShowS [TypeKind] -> ShowS TypeKind -> String (Int -> TypeKind -> ShowS) -> (TypeKind -> String) -> ([TypeKind] -> ShowS) -> Show TypeKind forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [TypeKind] -> ShowS $cshowList :: [TypeKind] -> ShowS show :: TypeKind -> String $cshow :: TypeKind -> String showsPrec :: Int -> TypeKind -> ShowS $cshowsPrec :: Int -> TypeKind -> ShowS Show, TypeKind -> TypeKind -> Bool (TypeKind -> TypeKind -> Bool) -> (TypeKind -> TypeKind -> Bool) -> Eq TypeKind forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: TypeKind -> TypeKind -> Bool $c/= :: TypeKind -> TypeKind -> Bool == :: TypeKind -> TypeKind -> Bool $c== :: TypeKind -> TypeKind -> Bool Eq, Eq TypeKind Eq TypeKind => (TypeKind -> TypeKind -> Ordering) -> (TypeKind -> TypeKind -> Bool) -> (TypeKind -> TypeKind -> Bool) -> (TypeKind -> TypeKind -> Bool) -> (TypeKind -> TypeKind -> Bool) -> (TypeKind -> TypeKind -> TypeKind) -> (TypeKind -> TypeKind -> TypeKind) -> Ord TypeKind TypeKind -> TypeKind -> Bool TypeKind -> TypeKind -> Ordering TypeKind -> TypeKind -> TypeKind forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: TypeKind -> TypeKind -> TypeKind $cmin :: TypeKind -> TypeKind -> TypeKind max :: TypeKind -> TypeKind -> TypeKind $cmax :: TypeKind -> TypeKind -> TypeKind >= :: TypeKind -> TypeKind -> Bool $c>= :: TypeKind -> TypeKind -> Bool > :: TypeKind -> TypeKind -> Bool $c> :: TypeKind -> TypeKind -> Bool <= :: TypeKind -> TypeKind -> Bool $c<= :: TypeKind -> TypeKind -> Bool < :: TypeKind -> TypeKind -> Bool $c< :: TypeKind -> TypeKind -> Bool compare :: TypeKind -> TypeKind -> Ordering $ccompare :: TypeKind -> TypeKind -> Ordering $cp1Ord :: Eq TypeKind Ord, Typeable, Typeable TypeKind Constr DataType Typeable TypeKind => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeKind -> c TypeKind) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeKind) -> (TypeKind -> Constr) -> (TypeKind -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeKind)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeKind)) -> ((forall b. Data b => b -> b) -> TypeKind -> TypeKind) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r) -> (forall u. (forall d. Data d => d -> u) -> TypeKind -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> TypeKind -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind) -> Data TypeKind TypeKind -> Constr TypeKind -> DataType (forall b. Data b => b -> b) -> TypeKind -> TypeKind (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeKind -> c TypeKind (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeKind forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> TypeKind -> u forall u. (forall d. Data d => d -> u) -> TypeKind -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeKind forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeKind -> c TypeKind forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeKind) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeKind) $cClassKind :: Constr $cDataTypeKind :: Constr $tTypeKind :: DataType gmapMo :: (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind gmapMp :: (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind gmapM :: (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeKind -> m TypeKind gmapQi :: Int -> (forall d. Data d => d -> u) -> TypeKind -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> TypeKind -> u gmapQ :: (forall d. Data d => d -> u) -> TypeKind -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> TypeKind -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeKind -> r gmapT :: (forall b. Data b => b -> b) -> TypeKind -> TypeKind $cgmapT :: (forall b. Data b => b -> b) -> TypeKind -> TypeKind dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeKind) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeKind) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c TypeKind) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeKind) dataTypeOf :: TypeKind -> DataType $cdataTypeOf :: TypeKind -> DataType toConstr :: TypeKind -> Constr $ctoConstr :: TypeKind -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeKind $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeKind gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeKind -> c TypeKind $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeKind -> c TypeKind $cp1Data :: Typeable TypeKind Data) instance Pretty TypeKind where pretty :: TypeKind -> Doc pretty DataTypeKind = String -> Doc text "datatype" pretty ClassKind = String -> Doc text "class" data TypeClass = TypeClass { TypeClass -> String name :: String, TypeClass -> TypeKind kind :: TypeKind } deriving (Int -> TypeClass -> ShowS [TypeClass] -> ShowS TypeClass -> String (Int -> TypeClass -> ShowS) -> (TypeClass -> String) -> ([TypeClass] -> ShowS) -> Show TypeClass forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [TypeClass] -> ShowS $cshowList :: [TypeClass] -> ShowS show :: TypeClass -> String $cshow :: TypeClass -> String showsPrec :: Int -> TypeClass -> ShowS $cshowsPrec :: Int -> TypeClass -> ShowS Show, TypeClass -> TypeClass -> Bool (TypeClass -> TypeClass -> Bool) -> (TypeClass -> TypeClass -> Bool) -> Eq TypeClass forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: TypeClass -> TypeClass -> Bool $c/= :: TypeClass -> TypeClass -> Bool == :: TypeClass -> TypeClass -> Bool $c== :: TypeClass -> TypeClass -> Bool Eq, Eq TypeClass Eq TypeClass => (TypeClass -> TypeClass -> Ordering) -> (TypeClass -> TypeClass -> Bool) -> (TypeClass -> TypeClass -> Bool) -> (TypeClass -> TypeClass -> Bool) -> (TypeClass -> TypeClass -> Bool) -> (TypeClass -> TypeClass -> TypeClass) -> (TypeClass -> TypeClass -> TypeClass) -> Ord TypeClass TypeClass -> TypeClass -> Bool TypeClass -> TypeClass -> Ordering TypeClass -> TypeClass -> TypeClass forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: TypeClass -> TypeClass -> TypeClass $cmin :: TypeClass -> TypeClass -> TypeClass max :: TypeClass -> TypeClass -> TypeClass $cmax :: TypeClass -> TypeClass -> TypeClass >= :: TypeClass -> TypeClass -> Bool $c>= :: TypeClass -> TypeClass -> Bool > :: TypeClass -> TypeClass -> Bool $c> :: TypeClass -> TypeClass -> Bool <= :: TypeClass -> TypeClass -> Bool $c<= :: TypeClass -> TypeClass -> Bool < :: TypeClass -> TypeClass -> Bool $c< :: TypeClass -> TypeClass -> Bool compare :: TypeClass -> TypeClass -> Ordering $ccompare :: TypeClass -> TypeClass -> Ordering $cp1Ord :: Eq TypeClass Ord, Typeable, Typeable TypeClass Constr DataType Typeable TypeClass => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeClass -> c TypeClass) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeClass) -> (TypeClass -> Constr) -> (TypeClass -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeClass)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeClass)) -> ((forall b. Data b => b -> b) -> TypeClass -> TypeClass) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r) -> (forall u. (forall d. Data d => d -> u) -> TypeClass -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> TypeClass -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass) -> Data TypeClass TypeClass -> Constr TypeClass -> DataType (forall b. Data b => b -> b) -> TypeClass -> TypeClass (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeClass -> c TypeClass (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeClass forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> TypeClass -> u forall u. (forall d. Data d => d -> u) -> TypeClass -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeClass forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeClass -> c TypeClass forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeClass) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeClass) $cTypeClass :: Constr $tTypeClass :: DataType gmapMo :: (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass gmapMp :: (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass gmapM :: (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> TypeClass -> m TypeClass gmapQi :: Int -> (forall d. Data d => d -> u) -> TypeClass -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> TypeClass -> u gmapQ :: (forall d. Data d => d -> u) -> TypeClass -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> TypeClass -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TypeClass -> r gmapT :: (forall b. Data b => b -> b) -> TypeClass -> TypeClass $cgmapT :: (forall b. Data b => b -> b) -> TypeClass -> TypeClass dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeClass) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TypeClass) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c TypeClass) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c TypeClass) dataTypeOf :: TypeClass -> DataType $cdataTypeOf :: TypeClass -> DataType toConstr :: TypeClass -> Constr $ctoConstr :: TypeClass -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeClass $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TypeClass gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeClass -> c TypeClass $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TypeClass -> c TypeClass $cp1Data :: Typeable TypeClass Data) instance Pretty TypeClass where pretty :: TypeClass -> Doc pretty (TypeClass nam :: String nam _) = String -> Doc text String nam type Role = String data PropertyT = PropertyT { PropertyT -> String sourceRole :: Role , PropertyT -> TypeClass sourceType :: TypeClass , PropertyT -> String targetRole :: Role , PropertyT -> TypeClass targetType :: TypeClass } deriving (Int -> PropertyT -> ShowS [PropertyT] -> ShowS PropertyT -> String (Int -> PropertyT -> ShowS) -> (PropertyT -> String) -> ([PropertyT] -> ShowS) -> Show PropertyT forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [PropertyT] -> ShowS $cshowList :: [PropertyT] -> ShowS show :: PropertyT -> String $cshow :: PropertyT -> String showsPrec :: Int -> PropertyT -> ShowS $cshowsPrec :: Int -> PropertyT -> ShowS Show, PropertyT -> PropertyT -> Bool (PropertyT -> PropertyT -> Bool) -> (PropertyT -> PropertyT -> Bool) -> Eq PropertyT forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: PropertyT -> PropertyT -> Bool $c/= :: PropertyT -> PropertyT -> Bool == :: PropertyT -> PropertyT -> Bool $c== :: PropertyT -> PropertyT -> Bool Eq, Eq PropertyT Eq PropertyT => (PropertyT -> PropertyT -> Ordering) -> (PropertyT -> PropertyT -> Bool) -> (PropertyT -> PropertyT -> Bool) -> (PropertyT -> PropertyT -> Bool) -> (PropertyT -> PropertyT -> Bool) -> (PropertyT -> PropertyT -> PropertyT) -> (PropertyT -> PropertyT -> PropertyT) -> Ord PropertyT PropertyT -> PropertyT -> Bool PropertyT -> PropertyT -> Ordering PropertyT -> PropertyT -> PropertyT forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: PropertyT -> PropertyT -> PropertyT $cmin :: PropertyT -> PropertyT -> PropertyT max :: PropertyT -> PropertyT -> PropertyT $cmax :: PropertyT -> PropertyT -> PropertyT >= :: PropertyT -> PropertyT -> Bool $c>= :: PropertyT -> PropertyT -> Bool > :: PropertyT -> PropertyT -> Bool $c> :: PropertyT -> PropertyT -> Bool <= :: PropertyT -> PropertyT -> Bool $c<= :: PropertyT -> PropertyT -> Bool < :: PropertyT -> PropertyT -> Bool $c< :: PropertyT -> PropertyT -> Bool compare :: PropertyT -> PropertyT -> Ordering $ccompare :: PropertyT -> PropertyT -> Ordering $cp1Ord :: Eq PropertyT Ord, Typeable, Typeable PropertyT Constr DataType Typeable PropertyT => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PropertyT -> c PropertyT) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PropertyT) -> (PropertyT -> Constr) -> (PropertyT -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c PropertyT)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PropertyT)) -> ((forall b. Data b => b -> b) -> PropertyT -> PropertyT) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r) -> (forall u. (forall d. Data d => d -> u) -> PropertyT -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> PropertyT -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT) -> Data PropertyT PropertyT -> Constr PropertyT -> DataType (forall b. Data b => b -> b) -> PropertyT -> PropertyT (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PropertyT -> c PropertyT (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PropertyT forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> PropertyT -> u forall u. (forall d. Data d => d -> u) -> PropertyT -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PropertyT forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PropertyT -> c PropertyT forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c PropertyT) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PropertyT) $cPropertyT :: Constr $tPropertyT :: DataType gmapMo :: (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT gmapMp :: (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT gmapM :: (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> PropertyT -> m PropertyT gmapQi :: Int -> (forall d. Data d => d -> u) -> PropertyT -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> PropertyT -> u gmapQ :: (forall d. Data d => d -> u) -> PropertyT -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> PropertyT -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PropertyT -> r gmapT :: (forall b. Data b => b -> b) -> PropertyT -> PropertyT $cgmapT :: (forall b. Data b => b -> b) -> PropertyT -> PropertyT dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PropertyT) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PropertyT) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c PropertyT) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c PropertyT) dataTypeOf :: PropertyT -> DataType $cdataTypeOf :: PropertyT -> DataType toConstr :: PropertyT -> Constr $ctoConstr :: PropertyT -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PropertyT $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PropertyT gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PropertyT -> c PropertyT $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PropertyT -> c PropertyT $cp1Data :: Typeable PropertyT Data) instance Pretty PropertyT where pretty :: PropertyT -> Doc pretty (PropertyT souR :: String souR souT :: TypeClass souT tarR :: String tarR tarT :: TypeClass tarT) = String -> Doc text "property" Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> Doc lparen Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> String -> Doc text String souR Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass souT Doc -> Doc -> Doc <+> Doc comma Doc -> Doc -> Doc <+> String -> Doc text String tarR Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass tarT Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> Doc rparen data LinkT = LinkT { LinkT -> String sourceVar :: Role , LinkT -> String targetVar :: Role , LinkT -> PropertyT property :: PropertyT } deriving (Int -> LinkT -> ShowS [LinkT] -> ShowS LinkT -> String (Int -> LinkT -> ShowS) -> (LinkT -> String) -> ([LinkT] -> ShowS) -> Show LinkT forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [LinkT] -> ShowS $cshowList :: [LinkT] -> ShowS show :: LinkT -> String $cshow :: LinkT -> String showsPrec :: Int -> LinkT -> ShowS $cshowsPrec :: Int -> LinkT -> ShowS Show, LinkT -> LinkT -> Bool (LinkT -> LinkT -> Bool) -> (LinkT -> LinkT -> Bool) -> Eq LinkT forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: LinkT -> LinkT -> Bool $c/= :: LinkT -> LinkT -> Bool == :: LinkT -> LinkT -> Bool $c== :: LinkT -> LinkT -> Bool Eq, Eq LinkT Eq LinkT => (LinkT -> LinkT -> Ordering) -> (LinkT -> LinkT -> Bool) -> (LinkT -> LinkT -> Bool) -> (LinkT -> LinkT -> Bool) -> (LinkT -> LinkT -> Bool) -> (LinkT -> LinkT -> LinkT) -> (LinkT -> LinkT -> LinkT) -> Ord LinkT LinkT -> LinkT -> Bool LinkT -> LinkT -> Ordering LinkT -> LinkT -> LinkT forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: LinkT -> LinkT -> LinkT $cmin :: LinkT -> LinkT -> LinkT max :: LinkT -> LinkT -> LinkT $cmax :: LinkT -> LinkT -> LinkT >= :: LinkT -> LinkT -> Bool $c>= :: LinkT -> LinkT -> Bool > :: LinkT -> LinkT -> Bool $c> :: LinkT -> LinkT -> Bool <= :: LinkT -> LinkT -> Bool $c<= :: LinkT -> LinkT -> Bool < :: LinkT -> LinkT -> Bool $c< :: LinkT -> LinkT -> Bool compare :: LinkT -> LinkT -> Ordering $ccompare :: LinkT -> LinkT -> Ordering $cp1Ord :: Eq LinkT Ord, Typeable, Typeable LinkT Constr DataType Typeable LinkT => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LinkT -> c LinkT) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c LinkT) -> (LinkT -> Constr) -> (LinkT -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c LinkT)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c LinkT)) -> ((forall b. Data b => b -> b) -> LinkT -> LinkT) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r) -> (forall u. (forall d. Data d => d -> u) -> LinkT -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> LinkT -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT) -> Data LinkT LinkT -> Constr LinkT -> DataType (forall b. Data b => b -> b) -> LinkT -> LinkT (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LinkT -> c LinkT (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c LinkT forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> LinkT -> u forall u. (forall d. Data d => d -> u) -> LinkT -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c LinkT forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LinkT -> c LinkT forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c LinkT) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c LinkT) $cLinkT :: Constr $tLinkT :: DataType gmapMo :: (forall d. Data d => d -> m d) -> LinkT -> m LinkT $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT gmapMp :: (forall d. Data d => d -> m d) -> LinkT -> m LinkT $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT gmapM :: (forall d. Data d => d -> m d) -> LinkT -> m LinkT $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> LinkT -> m LinkT gmapQi :: Int -> (forall d. Data d => d -> u) -> LinkT -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> LinkT -> u gmapQ :: (forall d. Data d => d -> u) -> LinkT -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> LinkT -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> LinkT -> r gmapT :: (forall b. Data b => b -> b) -> LinkT -> LinkT $cgmapT :: (forall b. Data b => b -> b) -> LinkT -> LinkT dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c LinkT) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c LinkT) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c LinkT) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c LinkT) dataTypeOf :: LinkT -> DataType $cdataTypeOf :: LinkT -> DataType toConstr :: LinkT -> Constr $ctoConstr :: LinkT -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c LinkT $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c LinkT gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LinkT -> c LinkT $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> LinkT -> c LinkT $cp1Data :: Typeable LinkT Data) instance Pretty LinkT where pretty :: LinkT -> Doc pretty (LinkT souV :: String souV tarV :: String tarV pro :: PropertyT pro) = String -> Doc text "link" Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> Doc lparen Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> String -> Doc text String souV Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> String -> Doc text (PropertyT -> String sourceRole PropertyT pro) Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty (PropertyT -> TypeClass sourceType PropertyT pro) Doc -> Doc -> Doc <+> Doc comma Doc -> Doc -> Doc <+> String -> Doc text String tarV Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> String -> Doc text (PropertyT -> String targetRole PropertyT pro) Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty (PropertyT -> TypeClass targetType PropertyT pro) Doc -> Doc -> Doc <+> Doc rparen data Sign = Sign { Sign -> Set TypeClass types :: Set.Set TypeClass , Sign -> Rel TypeClass typeRel :: Rel.Rel TypeClass , Sign -> Set TypeClass abstractClasses :: Set.Set TypeClass , Sign -> Set String roles :: Set.Set Role , Sign -> Set PropertyT properties :: Set.Set PropertyT , Sign -> Map String TypeClass instances :: Map.Map String TypeClass , Sign -> Set LinkT links :: Set.Set LinkT } deriving (Int -> Sign -> ShowS [Sign] -> ShowS Sign -> String (Int -> Sign -> ShowS) -> (Sign -> String) -> ([Sign] -> ShowS) -> Show Sign forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [Sign] -> ShowS $cshowList :: [Sign] -> ShowS show :: Sign -> String $cshow :: Sign -> String showsPrec :: Int -> Sign -> ShowS $cshowsPrec :: Int -> Sign -> ShowS Show, Sign -> Sign -> Bool (Sign -> Sign -> Bool) -> (Sign -> Sign -> Bool) -> Eq Sign forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: Sign -> Sign -> Bool $c/= :: Sign -> Sign -> Bool == :: Sign -> Sign -> Bool $c== :: Sign -> Sign -> Bool Eq, Eq Sign Eq Sign => (Sign -> Sign -> Ordering) -> (Sign -> Sign -> Bool) -> (Sign -> Sign -> Bool) -> (Sign -> Sign -> Bool) -> (Sign -> Sign -> Bool) -> (Sign -> Sign -> Sign) -> (Sign -> Sign -> Sign) -> Ord Sign Sign -> Sign -> Bool Sign -> Sign -> Ordering Sign -> Sign -> Sign forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: Sign -> Sign -> Sign $cmin :: Sign -> Sign -> Sign max :: Sign -> Sign -> Sign $cmax :: Sign -> Sign -> Sign >= :: Sign -> Sign -> Bool $c>= :: Sign -> Sign -> Bool > :: Sign -> Sign -> Bool $c> :: Sign -> Sign -> Bool <= :: Sign -> Sign -> Bool $c<= :: Sign -> Sign -> Bool < :: Sign -> Sign -> Bool $c< :: Sign -> Sign -> Bool compare :: Sign -> Sign -> Ordering $ccompare :: Sign -> Sign -> Ordering $cp1Ord :: Eq Sign Ord, Typeable, Typeable Sign Constr DataType Typeable Sign => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sign -> c Sign) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sign) -> (Sign -> Constr) -> (Sign -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sign)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sign)) -> ((forall b. Data b => b -> b) -> Sign -> Sign) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r) -> (forall u. (forall d. Data d => d -> u) -> Sign -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> Sign -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sign -> m Sign) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sign -> m Sign) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sign -> m Sign) -> Data Sign Sign -> Constr Sign -> DataType (forall b. Data b => b -> b) -> Sign -> Sign (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sign -> c Sign (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sign forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> Sign -> u forall u. (forall d. Data d => d -> u) -> Sign -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sign -> m Sign forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sign -> m Sign forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sign forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sign -> c Sign forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sign) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sign) $cSign :: Constr $tSign :: DataType gmapMo :: (forall d. Data d => d -> m d) -> Sign -> m Sign $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sign -> m Sign gmapMp :: (forall d. Data d => d -> m d) -> Sign -> m Sign $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sign -> m Sign gmapM :: (forall d. Data d => d -> m d) -> Sign -> m Sign $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sign -> m Sign gmapQi :: Int -> (forall d. Data d => d -> u) -> Sign -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> Sign -> u gmapQ :: (forall d. Data d => d -> u) -> Sign -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> Sign -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sign -> r gmapT :: (forall b. Data b => b -> b) -> Sign -> Sign $cgmapT :: (forall b. Data b => b -> b) -> Sign -> Sign dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sign) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sign) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c Sign) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sign) dataTypeOf :: Sign -> DataType $cdataTypeOf :: Sign -> DataType toConstr :: Sign -> Constr $ctoConstr :: Sign -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sign $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sign gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sign -> c Sign $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sign -> c Sign $cp1Data :: Typeable Sign Data) instance GetRange Sign where getRange :: Sign -> Range getRange _ = Range nullRange rangeSpan :: Sign -> [Pos] rangeSpan _ = [] instance Pretty Sign where pretty :: Sign -> Doc pretty (Sign typ :: Set TypeClass typ tyR :: Rel TypeClass tyR abst :: Set TypeClass abst rol :: Set String rol pro :: Set PropertyT pro ins :: Map String TypeClass ins lin :: Set LinkT lin) = (TypeClass -> Doc -> Doc) -> Doc -> Set TypeClass -> Doc forall a b. (a -> b -> b) -> b -> Set a -> b Set.fold (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> (TypeClass -> Doc) -> TypeClass -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . Set TypeClass -> TypeClass -> Doc toType Set TypeClass abst) Doc empty Set TypeClass typ Doc -> Doc -> Doc $++$ ((TypeClass, TypeClass) -> Doc -> Doc) -> Doc -> [(TypeClass, TypeClass)] -> Doc forall (t :: * -> *) a b. Foldable t => (a -> b -> b) -> b -> t a -> b foldr (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> ((TypeClass, TypeClass) -> Doc) -> (TypeClass, TypeClass) -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . (TypeClass, TypeClass) -> Doc toSubRel) Doc empty (Rel TypeClass -> [(TypeClass, TypeClass)] forall a. Rel a -> [(a, a)] Rel.toList Rel TypeClass tyR) Doc -> Doc -> Doc $++$ (String -> Doc -> Doc) -> Doc -> Set String -> Doc forall a b. (a -> b -> b) -> b -> Set a -> b Set.fold (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> (String -> Doc) -> String -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . String -> Doc text (String -> Doc) -> ShowS -> String -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . ("role " String -> ShowS forall a. [a] -> [a] -> [a] ++)) Doc empty Set String rol Doc -> Doc -> Doc $++$ (PropertyT -> Doc -> Doc) -> Doc -> Set PropertyT -> Doc forall a b. (a -> b -> b) -> b -> Set a -> b Set.fold (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> (PropertyT -> Doc) -> PropertyT -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . PropertyT -> Doc forall a. Pretty a => a -> Doc pretty) Doc empty Set PropertyT pro Doc -> Doc -> Doc $++$ ((String, TypeClass) -> Doc -> Doc) -> Doc -> [(String, TypeClass)] -> Doc forall (t :: * -> *) a b. Foldable t => (a -> b -> b) -> b -> t a -> b foldr (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> ((String, TypeClass) -> Doc) -> (String, TypeClass) -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . (String, TypeClass) -> Doc toInstance) Doc empty (Map String TypeClass -> [(String, TypeClass)] forall k a. Map k a -> [(k, a)] Map.toList Map String TypeClass ins) Doc -> Doc -> Doc $++$ (LinkT -> Doc -> Doc) -> Doc -> Set LinkT -> Doc forall a b. (a -> b -> b) -> b -> Set a -> b Set.fold (Doc -> Doc -> Doc ($+$) (Doc -> Doc -> Doc) -> (LinkT -> Doc) -> LinkT -> Doc -> Doc forall b c a. (b -> c) -> (a -> b) -> a -> c . LinkT -> Doc forall a. Pretty a => a -> Doc pretty) Doc empty Set LinkT lin toType :: Set.Set TypeClass -> TypeClass -> Doc toType :: Set TypeClass -> TypeClass -> Doc toType setTC :: Set TypeClass setTC (TypeClass nam :: String nam ki :: TypeKind ki) = if TypeClass -> Set TypeClass -> Bool forall a. Ord a => a -> Set a -> Bool Set.member (String -> TypeKind -> TypeClass TypeClass String nam TypeKind ki) Set TypeClass setTC then String -> Doc text "abstract" Doc -> Doc -> Doc <+> TypeKind -> Doc forall a. Pretty a => a -> Doc pretty TypeKind ki Doc -> Doc -> Doc <+> String -> Doc text String nam else TypeKind -> Doc forall a. Pretty a => a -> Doc pretty TypeKind ki Doc -> Doc -> Doc <+> String -> Doc text String nam toSubRel :: (TypeClass, TypeClass) -> Doc toSubRel :: (TypeClass, TypeClass) -> Doc toSubRel (a :: TypeClass a, b :: TypeClass b) = TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass a Doc -> Doc -> Doc <+> String -> Doc text "<" Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass b toInstance :: (String, TypeClass) -> Doc toInstance :: (String, TypeClass) -> Doc toInstance (a :: String a, b :: TypeClass b) = String -> Doc text "object" Doc -> Doc -> Doc <+> String -> Doc text String a Doc -> Doc -> Doc <+> Doc colon Doc -> Doc -> Doc <+> TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass b emptySign :: Sign emptySign :: Sign emptySign = Sign :: Set TypeClass -> Rel TypeClass -> Set TypeClass -> Set String -> Set PropertyT -> Map String TypeClass -> Set LinkT -> Sign Sign { types :: Set TypeClass types = Set TypeClass forall a. Set a Set.empty , typeRel :: Rel TypeClass typeRel = Rel TypeClass forall a. Rel a Rel.empty , abstractClasses :: Set TypeClass abstractClasses = Set TypeClass forall a. Set a Set.empty , roles :: Set String roles = Set String forall a. Set a Set.empty , properties :: Set PropertyT properties = Set PropertyT forall a. Set a Set.empty , instances :: Map String TypeClass instances = Map String TypeClass forall k a. Map k a Map.empty , links :: Set LinkT links = Set LinkT forall a. Set a Set.empty } {- signUnion :: Sign -> Sign -> Result Sign signUnion s1 s2 = return s1 { rels = Map.unionWith Set.union (rels s1) (rels s2) , isas = Rel.union (isas s1) (isas s2) } -} data MultConstr = MultConstr { MultConstr -> TypeClass getType :: TypeClass , MultConstr -> String getRole :: Role } deriving (Int -> MultConstr -> ShowS [MultConstr] -> ShowS MultConstr -> String (Int -> MultConstr -> ShowS) -> (MultConstr -> String) -> ([MultConstr] -> ShowS) -> Show MultConstr forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [MultConstr] -> ShowS $cshowList :: [MultConstr] -> ShowS show :: MultConstr -> String $cshow :: MultConstr -> String showsPrec :: Int -> MultConstr -> ShowS $cshowsPrec :: Int -> MultConstr -> ShowS Show, MultConstr -> MultConstr -> Bool (MultConstr -> MultConstr -> Bool) -> (MultConstr -> MultConstr -> Bool) -> Eq MultConstr forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: MultConstr -> MultConstr -> Bool $c/= :: MultConstr -> MultConstr -> Bool == :: MultConstr -> MultConstr -> Bool $c== :: MultConstr -> MultConstr -> Bool Eq, Eq MultConstr Eq MultConstr => (MultConstr -> MultConstr -> Ordering) -> (MultConstr -> MultConstr -> Bool) -> (MultConstr -> MultConstr -> Bool) -> (MultConstr -> MultConstr -> Bool) -> (MultConstr -> MultConstr -> Bool) -> (MultConstr -> MultConstr -> MultConstr) -> (MultConstr -> MultConstr -> MultConstr) -> Ord MultConstr MultConstr -> MultConstr -> Bool MultConstr -> MultConstr -> Ordering MultConstr -> MultConstr -> MultConstr forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: MultConstr -> MultConstr -> MultConstr $cmin :: MultConstr -> MultConstr -> MultConstr max :: MultConstr -> MultConstr -> MultConstr $cmax :: MultConstr -> MultConstr -> MultConstr >= :: MultConstr -> MultConstr -> Bool $c>= :: MultConstr -> MultConstr -> Bool > :: MultConstr -> MultConstr -> Bool $c> :: MultConstr -> MultConstr -> Bool <= :: MultConstr -> MultConstr -> Bool $c<= :: MultConstr -> MultConstr -> Bool < :: MultConstr -> MultConstr -> Bool $c< :: MultConstr -> MultConstr -> Bool compare :: MultConstr -> MultConstr -> Ordering $ccompare :: MultConstr -> MultConstr -> Ordering $cp1Ord :: Eq MultConstr Ord, Typeable, Typeable MultConstr Constr DataType Typeable MultConstr => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MultConstr -> c MultConstr) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MultConstr) -> (MultConstr -> Constr) -> (MultConstr -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c MultConstr)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c MultConstr)) -> ((forall b. Data b => b -> b) -> MultConstr -> MultConstr) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r) -> (forall u. (forall d. Data d => d -> u) -> MultConstr -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> MultConstr -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr) -> Data MultConstr MultConstr -> Constr MultConstr -> DataType (forall b. Data b => b -> b) -> MultConstr -> MultConstr (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MultConstr -> c MultConstr (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MultConstr forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> MultConstr -> u forall u. (forall d. Data d => d -> u) -> MultConstr -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MultConstr forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MultConstr -> c MultConstr forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c MultConstr) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c MultConstr) $cMultConstr :: Constr $tMultConstr :: DataType gmapMo :: (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr gmapMp :: (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr gmapM :: (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> MultConstr -> m MultConstr gmapQi :: Int -> (forall d. Data d => d -> u) -> MultConstr -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> MultConstr -> u gmapQ :: (forall d. Data d => d -> u) -> MultConstr -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> MultConstr -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> MultConstr -> r gmapT :: (forall b. Data b => b -> b) -> MultConstr -> MultConstr $cgmapT :: (forall b. Data b => b -> b) -> MultConstr -> MultConstr dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c MultConstr) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c MultConstr) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c MultConstr) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c MultConstr) dataTypeOf :: MultConstr -> DataType $cdataTypeOf :: MultConstr -> DataType toConstr :: MultConstr -> Constr $ctoConstr :: MultConstr -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MultConstr $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MultConstr gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MultConstr -> c MultConstr $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MultConstr -> c MultConstr $cp1Data :: Typeable MultConstr Data) instance Pretty MultConstr where pretty :: MultConstr -> Doc pretty (MultConstr tc :: TypeClass tc ro :: String ro) = TypeClass -> Doc forall a. Pretty a => a -> Doc pretty TypeClass tc Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> String -> Doc text "." Doc -> Doc -> Doc forall a. Semigroup a => a -> a -> a <> String -> Doc text String ro data ConstraintType = EQUAL | LEQ | GEQ deriving (Int -> ConstraintType -> ShowS [ConstraintType] -> ShowS ConstraintType -> String (Int -> ConstraintType -> ShowS) -> (ConstraintType -> String) -> ([ConstraintType] -> ShowS) -> Show ConstraintType forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [ConstraintType] -> ShowS $cshowList :: [ConstraintType] -> ShowS show :: ConstraintType -> String $cshow :: ConstraintType -> String showsPrec :: Int -> ConstraintType -> ShowS $cshowsPrec :: Int -> ConstraintType -> ShowS Show, ConstraintType -> ConstraintType -> Bool (ConstraintType -> ConstraintType -> Bool) -> (ConstraintType -> ConstraintType -> Bool) -> Eq ConstraintType forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: ConstraintType -> ConstraintType -> Bool $c/= :: ConstraintType -> ConstraintType -> Bool == :: ConstraintType -> ConstraintType -> Bool $c== :: ConstraintType -> ConstraintType -> Bool Eq, Eq ConstraintType Eq ConstraintType => (ConstraintType -> ConstraintType -> Ordering) -> (ConstraintType -> ConstraintType -> Bool) -> (ConstraintType -> ConstraintType -> Bool) -> (ConstraintType -> ConstraintType -> Bool) -> (ConstraintType -> ConstraintType -> Bool) -> (ConstraintType -> ConstraintType -> ConstraintType) -> (ConstraintType -> ConstraintType -> ConstraintType) -> Ord ConstraintType ConstraintType -> ConstraintType -> Bool ConstraintType -> ConstraintType -> Ordering ConstraintType -> ConstraintType -> ConstraintType forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: ConstraintType -> ConstraintType -> ConstraintType $cmin :: ConstraintType -> ConstraintType -> ConstraintType max :: ConstraintType -> ConstraintType -> ConstraintType $cmax :: ConstraintType -> ConstraintType -> ConstraintType >= :: ConstraintType -> ConstraintType -> Bool $c>= :: ConstraintType -> ConstraintType -> Bool > :: ConstraintType -> ConstraintType -> Bool $c> :: ConstraintType -> ConstraintType -> Bool <= :: ConstraintType -> ConstraintType -> Bool $c<= :: ConstraintType -> ConstraintType -> Bool < :: ConstraintType -> ConstraintType -> Bool $c< :: ConstraintType -> ConstraintType -> Bool compare :: ConstraintType -> ConstraintType -> Ordering $ccompare :: ConstraintType -> ConstraintType -> Ordering $cp1Ord :: Eq ConstraintType Ord, Typeable, Typeable ConstraintType Constr DataType Typeable ConstraintType => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConstraintType -> c ConstraintType) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConstraintType) -> (ConstraintType -> Constr) -> (ConstraintType -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ConstraintType)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConstraintType)) -> ((forall b. Data b => b -> b) -> ConstraintType -> ConstraintType) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r) -> (forall u. (forall d. Data d => d -> u) -> ConstraintType -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> ConstraintType -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType) -> Data ConstraintType ConstraintType -> Constr ConstraintType -> DataType (forall b. Data b => b -> b) -> ConstraintType -> ConstraintType (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConstraintType -> c ConstraintType (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConstraintType forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> ConstraintType -> u forall u. (forall d. Data d => d -> u) -> ConstraintType -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConstraintType forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConstraintType -> c ConstraintType forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ConstraintType) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConstraintType) $cGEQ :: Constr $cLEQ :: Constr $cEQUAL :: Constr $tConstraintType :: DataType gmapMo :: (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType gmapMp :: (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType gmapM :: (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> ConstraintType -> m ConstraintType gmapQi :: Int -> (forall d. Data d => d -> u) -> ConstraintType -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> ConstraintType -> u gmapQ :: (forall d. Data d => d -> u) -> ConstraintType -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> ConstraintType -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConstraintType -> r gmapT :: (forall b. Data b => b -> b) -> ConstraintType -> ConstraintType $cgmapT :: (forall b. Data b => b -> b) -> ConstraintType -> ConstraintType dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConstraintType) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConstraintType) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c ConstraintType) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ConstraintType) dataTypeOf :: ConstraintType -> DataType $cdataTypeOf :: ConstraintType -> DataType toConstr :: ConstraintType -> Constr $ctoConstr :: ConstraintType -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConstraintType $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConstraintType gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConstraintType -> c ConstraintType $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConstraintType -> c ConstraintType $cp1Data :: Typeable ConstraintType Data) instance Pretty ConstraintType where pretty :: ConstraintType -> Doc pretty EQUAL = Doc equals pretty LEQ = String -> Doc text "<=" pretty GEQ = String -> Doc text ">=" data Sen = Sen { Sen -> MultConstr constraint :: MultConstr , Sen -> Integer cardinality :: Integer , Sen -> ConstraintType constraintType :: ConstraintType } deriving (Int -> Sen -> ShowS [Sen] -> ShowS Sen -> String (Int -> Sen -> ShowS) -> (Sen -> String) -> ([Sen] -> ShowS) -> Show Sen forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [Sen] -> ShowS $cshowList :: [Sen] -> ShowS show :: Sen -> String $cshow :: Sen -> String showsPrec :: Int -> Sen -> ShowS $cshowsPrec :: Int -> Sen -> ShowS Show, Sen -> Sen -> Bool (Sen -> Sen -> Bool) -> (Sen -> Sen -> Bool) -> Eq Sen forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: Sen -> Sen -> Bool $c/= :: Sen -> Sen -> Bool == :: Sen -> Sen -> Bool $c== :: Sen -> Sen -> Bool Eq, Eq Sen Eq Sen => (Sen -> Sen -> Ordering) -> (Sen -> Sen -> Bool) -> (Sen -> Sen -> Bool) -> (Sen -> Sen -> Bool) -> (Sen -> Sen -> Bool) -> (Sen -> Sen -> Sen) -> (Sen -> Sen -> Sen) -> Ord Sen Sen -> Sen -> Bool Sen -> Sen -> Ordering Sen -> Sen -> Sen forall a. Eq a => (a -> a -> Ordering) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> Bool) -> (a -> a -> a) -> (a -> a -> a) -> Ord a min :: Sen -> Sen -> Sen $cmin :: Sen -> Sen -> Sen max :: Sen -> Sen -> Sen $cmax :: Sen -> Sen -> Sen >= :: Sen -> Sen -> Bool $c>= :: Sen -> Sen -> Bool > :: Sen -> Sen -> Bool $c> :: Sen -> Sen -> Bool <= :: Sen -> Sen -> Bool $c<= :: Sen -> Sen -> Bool < :: Sen -> Sen -> Bool $c< :: Sen -> Sen -> Bool compare :: Sen -> Sen -> Ordering $ccompare :: Sen -> Sen -> Ordering $cp1Ord :: Eq Sen Ord, Typeable, Typeable Sen Constr DataType Typeable Sen => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sen -> c Sen) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sen) -> (Sen -> Constr) -> (Sen -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sen)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sen)) -> ((forall b. Data b => b -> b) -> Sen -> Sen) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r) -> (forall u. (forall d. Data d => d -> u) -> Sen -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> Sen -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sen -> m Sen) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sen -> m Sen) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sen -> m Sen) -> Data Sen Sen -> Constr Sen -> DataType (forall b. Data b => b -> b) -> Sen -> Sen (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sen -> c Sen (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sen forall a. Typeable a => (forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> a -> c a) -> (forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c a) -> (a -> Constr) -> (a -> DataType) -> (forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c a)) -> (forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a)) -> ((forall b. Data b => b -> b) -> a -> a) -> (forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r) -> (forall u. (forall d. Data d => d -> u) -> a -> [u]) -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u) -> (forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> (forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> a -> m a) -> Data a forall u. Int -> (forall d. Data d => d -> u) -> Sen -> u forall u. (forall d. Data d => d -> u) -> Sen -> [u] forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sen -> m Sen forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sen -> m Sen forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sen forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sen -> c Sen forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sen) forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sen) $cSen :: Constr $tSen :: DataType gmapMo :: (forall d. Data d => d -> m d) -> Sen -> m Sen $cgmapMo :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sen -> m Sen gmapMp :: (forall d. Data d => d -> m d) -> Sen -> m Sen $cgmapMp :: forall (m :: * -> *). MonadPlus m => (forall d. Data d => d -> m d) -> Sen -> m Sen gmapM :: (forall d. Data d => d -> m d) -> Sen -> m Sen $cgmapM :: forall (m :: * -> *). Monad m => (forall d. Data d => d -> m d) -> Sen -> m Sen gmapQi :: Int -> (forall d. Data d => d -> u) -> Sen -> u $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> Sen -> u gmapQ :: (forall d. Data d => d -> u) -> Sen -> [u] $cgmapQ :: forall u. (forall d. Data d => d -> u) -> Sen -> [u] gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r $cgmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r $cgmapQl :: forall r r'. (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Sen -> r gmapT :: (forall b. Data b => b -> b) -> Sen -> Sen $cgmapT :: (forall b. Data b => b -> b) -> Sen -> Sen dataCast2 :: (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sen) $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *). Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Sen) dataCast1 :: (forall d. Data d => c (t d)) -> Maybe (c Sen) $cdataCast1 :: forall (t :: * -> *) (c :: * -> *). Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Sen) dataTypeOf :: Sen -> DataType $cdataTypeOf :: Sen -> DataType toConstr :: Sen -> Constr $ctoConstr :: Sen -> Constr gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sen $cgunfold :: forall (c :: * -> *). (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Sen gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sen -> c Sen $cgfoldl :: forall (c :: * -> *). (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Sen -> c Sen $cp1Data :: Typeable Sen Data) instance GetRange Sen where getRange :: Sen -> Range getRange _ = Range nullRange rangeSpan :: Sen -> [Pos] rangeSpan _ = [] instance Pretty Sen where pretty :: Sen -> Doc pretty (Sen con :: MultConstr con car :: Integer car cty :: ConstraintType cty) = MultConstr -> Doc forall a. Pretty a => a -> Doc pretty MultConstr con Doc -> Doc -> Doc <+> ConstraintType -> Doc forall a. Pretty a => a -> Doc pretty ConstraintType cty Doc -> Doc -> Doc <+> Integer -> Doc forall a. Pretty a => a -> Doc pretty Integer car