Copyright | (c) Sonja Groening C. Maeder and Uni Bremen 2002-2006 |
---|---|
License | GPLv2 or higher, see LICENSE.txt |
Maintainer | Christian.Maeder@dfki.de |
Stability | experimental |
Portability | portable |
Safe Haskell | None |
This module provides the sublogic functions (as required by Logic.hs) for HasCASL. The functions allow to compute the minimal sublogic needed by a given element, to check whether an item is part of a given sublogic, and -- not yet -- to project an element into a given sublogic.
Synopsis
- data Sublogic = Sublogic {
- has_sub :: Bool
- has_part :: Bool
- has_eq :: Bool
- has_pred :: Bool
- type_classes :: Classes
- has_polymorphism :: Bool
- has_type_constructors :: Bool
- has_products :: Bool
- which_logic :: Formulas
- data Formulas
- data Classes
- topLogic :: Sublogic
- sublogic_max :: Sublogic -> Sublogic -> Sublogic
- sublogic_min :: Sublogic -> Sublogic -> Sublogic
- sublogicUp :: Sublogic -> Sublogic
- need_hol :: Sublogic
- bottom :: Sublogic
- noSubtypes :: Sublogic
- noClasses :: Sublogic
- totalFuns :: Sublogic
- caslLogic :: Sublogic
- sublogic_name :: Sublogic -> String
- sublogics_all :: [Sublogic]
- in_basicSpec :: Sublogic -> BasicSpec -> Bool
- in_sentence :: Sublogic -> Sentence -> Bool
- in_symbItems :: Sublogic -> SymbItems -> Bool
- in_symbMapItems :: Sublogic -> SymbMapItems -> Bool
- in_env :: Sublogic -> Env -> Bool
- in_morphism :: Sublogic -> Morphism -> Bool
- in_symbol :: Sublogic -> Symbol -> Bool
- sl_basicSpec :: BasicSpec -> Sublogic
- sl_sentence :: Sentence -> Sublogic
- sl_symbItems :: SymbItems -> Sublogic
- sl_symbMapItems :: SymbMapItems -> Sublogic
- sl_env :: Env -> Sublogic
- sl_morphism :: Morphism -> Sublogic
- sl_symbol :: Symbol -> Sublogic
datatypes
HasCASL sublogics
Sublogic | |
|
Instances
formula kinds of HasCASL sublogics
Atomic | atomic logic |
Horn | positive conditional logic |
GHorn | generalized positive conditional logic |
FOL | first-order logic |
HOL | higher-order logic |
Instances
Eq Formulas Source # | |
Data Formulas Source # | |
Defined in HasCASL.Sublogic gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Formulas -> c Formulas gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Formulas toConstr :: Formulas -> Constr dataTypeOf :: Formulas -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Formulas) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Formulas) gmapT :: (forall b. Data b => b -> b) -> Formulas -> Formulas gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Formulas -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Formulas -> r gmapQ :: (forall d. Data d => d -> u) -> Formulas -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> Formulas -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> Formulas -> m Formulas gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Formulas -> m Formulas gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Formulas -> m Formulas | |
Ord Formulas Source # | |
Show Formulas Source # | |
Generic Formulas | |
FromJSON Formulas | |
Defined in HasCASL.ATC_HasCASL parseJSON :: Value -> Parser Formulas parseJSONList :: Value -> Parser [Formulas] | |
ToJSON Formulas | |
Defined in HasCASL.ATC_HasCASL toEncoding :: Formulas -> Encoding toJSONList :: [Formulas] -> Value toEncodingList :: [Formulas] -> Encoding | |
ShATermConvertible Formulas | |
Defined in HasCASL.ATC_HasCASL toShATermAux :: ATermTable -> Formulas -> IO (ATermTable, Int) toShATermList' :: ATermTable -> [Formulas] -> IO (ATermTable, Int) fromShATermAux :: Int -> ATermTable -> (ATermTable, Formulas) fromShATermList' :: Int -> ATermTable -> (ATermTable, [Formulas]) | |
type Rep Formulas | |
Defined in HasCASL.ATC_HasCASL type Rep Formulas = D1 ('MetaData "Formulas" "HasCASL.Sublogic" "main" 'False) ((C1 ('MetaCons "Atomic" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "Horn" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "GHorn" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "FOL" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "HOL" 'PrefixI 'False) (U1 :: Type -> Type)))) |
Instances
Eq Classes Source # | |
Data Classes Source # | |
Defined in HasCASL.Sublogic gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Classes -> c Classes gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Classes dataTypeOf :: Classes -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Classes) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Classes) gmapT :: (forall b. Data b => b -> b) -> Classes -> Classes gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Classes -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Classes -> r gmapQ :: (forall d. Data d => d -> u) -> Classes -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> Classes -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> Classes -> m Classes gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Classes -> m Classes gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Classes -> m Classes | |
Ord Classes Source # | |
Show Classes Source # | |
Generic Classes | |
FromJSON Classes | |
Defined in HasCASL.ATC_HasCASL parseJSON :: Value -> Parser Classes parseJSONList :: Value -> Parser [Classes] | |
ToJSON Classes | |
Defined in HasCASL.ATC_HasCASL toEncoding :: Classes -> Encoding toJSONList :: [Classes] -> Value toEncodingList :: [Classes] -> Encoding | |
ShATermConvertible Classes | |
Defined in HasCASL.ATC_HasCASL toShATermAux :: ATermTable -> Classes -> IO (ATermTable, Int) toShATermList' :: ATermTable -> [Classes] -> IO (ATermTable, Int) fromShATermAux :: Int -> ATermTable -> (ATermTable, Classes) fromShATermList' :: Int -> ATermTable -> (ATermTable, [Classes]) | |
type Rep Classes | |
Defined in HasCASL.ATC_HasCASL type Rep Classes = D1 ('MetaData "Classes" "HasCASL.Sublogic" "main" 'False) (C1 ('MetaCons "NoClasses" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "SimpleTypeClasses" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "ConstructorClasses" 'PrefixI 'False) (U1 :: Type -> Type))) |
functions for SemiLatticeWithTop instance
combining sublogics restrictions
sublogicUp :: Sublogic -> Sublogic Source #
make sublogic consistent w.r.t. illegal combinations
further sublogic constants
noSubtypes :: Sublogic Source #
top sublogic without subtypes
functions for Logic instance
sublogic to string converstion
sublogic_name :: Sublogic -> String Source #
the sublogic name as a singleton string list
list of all sublogics
sublogics_all :: [Sublogic] Source #
generate a list of all sublogics for HasCASL
checks if element is in given sublogic
in_basicSpec :: Sublogic -> BasicSpec -> Bool Source #
in_sentence :: Sublogic -> Sentence -> Bool Source #
in_symbItems :: Sublogic -> SymbItems -> Bool Source #
in_symbMapItems :: Sublogic -> SymbMapItems -> Bool Source #
in_morphism :: Sublogic -> Morphism -> Bool Source #
computes the sublogic of a given element
sl_basicSpec :: BasicSpec -> Sublogic Source #
sl_sentence :: Sentence -> Sublogic Source #
sl_symbItems :: SymbItems -> Sublogic Source #
sl_morphism :: Morphism -> Sublogic Source #