{-# OPTIONS -w -O0 #-}
{-# LANGUAGE CPP, StandaloneDeriving, DeriveDataTypeable, DeriveGeneric #-}
module ATC.AS_Structured () where
import ATC.Grothendieck
import ATerm.Lib
import Common.AS_Annotation
import Common.IRI
import Common.Id
import Data.Typeable
import Logic.Grothendieck (G_basic_spec
, G_symb_items_list
, G_symb_map_items_list
, LogicGraph
, setCurLogic
, setSyntax )
import Logic.Logic
import Syntax.AS_Structured
import qualified Data.Set as Set
instance ShATermLG Syntax.AS_Structured.SPEC where
toShATermLG :: ATermTable -> SPEC -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: SPEC
xv = case SPEC
xv of
Basic_spec a :: G_basic_spec
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> G_basic_spec -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 G_basic_spec
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Basic_spec" [Int
a', Int
b'] []) ATermTable
att2
EmptySpec a :: Range
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Range
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "EmptySpec" [Int
a'] []) ATermTable
att1
Extraction a :: Annoted SPEC
a b :: EXTRACTION
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> EXTRACTION -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 EXTRACTION
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Extraction" [Int
a', Int
b'] []) ATermTable
att2
Translation a :: Annoted SPEC
a b :: RENAMING
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> RENAMING -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 RENAMING
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Translation" [Int
a', Int
b'] []) ATermTable
att2
Reduction a :: Annoted SPEC
a b :: RESTRICTION
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> RESTRICTION -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 RESTRICTION
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Reduction" [Int
a', Int
b'] []) ATermTable
att2
Approximation a :: Annoted SPEC
a b :: APPROXIMATION
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> APPROXIMATION -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 APPROXIMATION
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Approximation" [Int
a', Int
b'] []) ATermTable
att2
Minimization a :: Annoted SPEC
a b :: MINIMIZATION
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> MINIMIZATION -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 MINIMIZATION
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Minimization" [Int
a', Int
b'] []) ATermTable
att2
Filtering a :: Annoted SPEC
a b :: FILTERING
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> FILTERING -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 FILTERING
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Filtering" [Int
a', Int
b'] []) ATermTable
att2
Bridge a :: Annoted SPEC
a b :: [RENAMING]
b c :: Annoted SPEC
c d :: Range
d -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [RENAMING] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [RENAMING]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Annoted SPEC
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Range
d
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Bridge" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
Union a :: [Annoted SPEC]
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [Annoted SPEC] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [Annoted SPEC]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Union" [Int
a', Int
b'] []) ATermTable
att2
Intersection a :: [Annoted SPEC]
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [Annoted SPEC] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [Annoted SPEC]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Intersection" [Int
a', Int
b'] []) ATermTable
att2
Extension a :: [Annoted SPEC]
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [Annoted SPEC] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [Annoted SPEC]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Extension" [Int
a', Int
b'] []) ATermTable
att2
Free_spec a :: Annoted SPEC
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Free_spec" [Int
a', Int
b'] []) ATermTable
att2
Cofree_spec a :: Annoted SPEC
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Cofree_spec" [Int
a', Int
b'] []) ATermTable
att2
Minimize_spec a :: Annoted SPEC
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Minimize_spec" [Int
a', Int
b'] []) ATermTable
att2
Local_spec a :: Annoted SPEC
a b :: Annoted SPEC
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Annoted SPEC
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Local_spec" [Int
a', Int
b', Int
c'] []) ATermTable
att3
Closed_spec a :: Annoted SPEC
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Closed_spec" [Int
a', Int
b'] []) ATermTable
att2
Group a :: Annoted SPEC
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Group" [Int
a', Int
b'] []) ATermTable
att2
Spec_inst a :: SPEC_NAME
a b :: [Annoted FIT_ARG]
b c :: Maybe SPEC_NAME
c d :: Range
d -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [Annoted FIT_ARG] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [Annoted FIT_ARG]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Maybe SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Maybe SPEC_NAME
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Range
d
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Spec_inst" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
Qualified_spec a :: LogicDescr
a b :: Annoted SPEC
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> LogicDescr -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 LogicDescr
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Annoted SPEC
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Qualified_spec" [Int
a', Int
b', Int
c'] []) ATermTable
att3
Data a :: AnyLogic
a b :: AnyLogic
b c :: Annoted SPEC
c d :: Annoted SPEC
d e :: Range
e -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> AnyLogic -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 AnyLogic
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> AnyLogic -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 AnyLogic
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Annoted SPEC
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Annoted SPEC
d
(att5 :: ATermTable
att5, e' :: Int
e') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att4 Range
e
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Data" [Int
a', Int
b', Int
c', Int
d', Int
e'] []) ATermTable
att5
Combination a :: Network
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Network -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Network
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Combination" [Int
a', Int
b'] []) ATermTable
att2
Apply a :: SPEC_NAME
a b :: G_basic_spec
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> G_basic_spec -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 G_basic_spec
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Apply" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Basic_spec" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_basic_spec)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: G_basic_spec
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, G_basic_spec -> Range -> SPEC
Basic_spec G_basic_spec
a' Range
b') }}
ShAAppl "EmptySpec" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Range
a') ->
(ATermTable
att1, Range -> SPEC
EmptySpec Range
a') }
ShAAppl "Extraction" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, EXTRACTION)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: EXTRACTION
b') ->
(ATermTable
att2, Annoted SPEC -> EXTRACTION -> SPEC
Extraction Annoted SPEC
a' EXTRACTION
b') }}
ShAAppl "Translation" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, RENAMING)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: RENAMING
b') ->
(ATermTable
att2, Annoted SPEC -> RENAMING -> SPEC
Translation Annoted SPEC
a' RENAMING
b') }}
ShAAppl "Reduction" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, RESTRICTION)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: RESTRICTION
b') ->
(ATermTable
att2, Annoted SPEC -> RESTRICTION -> SPEC
Reduction Annoted SPEC
a' RESTRICTION
b') }}
ShAAppl "Approximation" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, APPROXIMATION)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: APPROXIMATION
b') ->
(ATermTable
att2, Annoted SPEC -> APPROXIMATION -> SPEC
Approximation Annoted SPEC
a' APPROXIMATION
b') }}
ShAAppl "Minimization" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, MINIMIZATION)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: MINIMIZATION
b') ->
(ATermTable
att2, Annoted SPEC -> MINIMIZATION -> SPEC
Minimization Annoted SPEC
a' MINIMIZATION
b') }}
ShAAppl "Filtering" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, FILTERING)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: FILTERING
b') ->
(ATermTable
att2, Annoted SPEC -> FILTERING -> SPEC
Filtering Annoted SPEC
a' FILTERING
b') }}
ShAAppl "Bridge" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [RENAMING])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [RENAMING]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Annoted SPEC
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Range
d') ->
(ATermTable
att4, Annoted SPEC -> [RENAMING] -> Annoted SPEC -> Range -> SPEC
Bridge Annoted SPEC
a' [RENAMING]
b' Annoted SPEC
c' Range
d') }}}}
ShAAppl "Union" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [Annoted SPEC])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [Annoted SPEC]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, [Annoted SPEC] -> Range -> SPEC
Union [Annoted SPEC]
a' Range
b') }}
ShAAppl "Intersection" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [Annoted SPEC])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [Annoted SPEC]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, [Annoted SPEC] -> Range -> SPEC
Intersection [Annoted SPEC]
a' Range
b') }}
ShAAppl "Extension" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [Annoted SPEC])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [Annoted SPEC]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, [Annoted SPEC] -> Range -> SPEC
Extension [Annoted SPEC]
a' Range
b') }}
ShAAppl "Free_spec" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Annoted SPEC -> Range -> SPEC
Free_spec Annoted SPEC
a' Range
b') }}
ShAAppl "Cofree_spec" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Annoted SPEC -> Range -> SPEC
Cofree_spec Annoted SPEC
a' Range
b') }}
ShAAppl "Minimize_spec" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Annoted SPEC -> Range -> SPEC
Minimize_spec Annoted SPEC
a' Range
b') }}
ShAAppl "Local_spec" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Annoted SPEC
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Annoted SPEC -> Annoted SPEC -> Range -> SPEC
Local_spec Annoted SPEC
a' Annoted SPEC
b' Range
c') }}}
ShAAppl "Closed_spec" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Annoted SPEC -> Range -> SPEC
Closed_spec Annoted SPEC
a' Range
b') }}
ShAAppl "Group" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Annoted SPEC -> Range -> SPEC
Group Annoted SPEC
a' Range
b') }}
ShAAppl "Spec_inst" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [Annoted FIT_ARG])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [Annoted FIT_ARG]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Maybe SPEC_NAME
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Range
d') ->
(ATermTable
att4, SPEC_NAME -> [Annoted FIT_ARG] -> Maybe SPEC_NAME -> Range -> SPEC
Spec_inst SPEC_NAME
a' [Annoted FIT_ARG]
b' Maybe SPEC_NAME
c' Range
d') }}}}
ShAAppl "Qualified_spec" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, LogicDescr)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: LogicDescr
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Annoted SPEC
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, LogicDescr -> Annoted SPEC -> Range -> SPEC
Qualified_spec LogicDescr
a' Annoted SPEC
b' Range
c') }}}
ShAAppl "Data" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d, e :: Int
e] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, AnyLogic)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: AnyLogic
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, AnyLogic)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: AnyLogic
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Annoted SPEC
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Annoted SPEC
d') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
e ATermTable
att4 of
{ (att5 :: ATermTable
att5, e' :: Range
e') ->
(ATermTable
att5, AnyLogic
-> AnyLogic -> Annoted SPEC -> Annoted SPEC -> Range -> SPEC
Data AnyLogic
a' AnyLogic
b' Annoted SPEC
c' Annoted SPEC
d' Range
e') }}}}}
ShAAppl "Combination" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Network)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Network
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, Network -> Range -> SPEC
Combination Network
a' Range
b') }}
ShAAppl "Apply" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_basic_spec)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: G_basic_spec
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, SPEC_NAME -> G_basic_spec -> Range -> SPEC
Apply SPEC_NAME
a' G_basic_spec
b' Range
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, SPEC)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.SPEC" ShATerm
u
instance ShATermLG Syntax.AS_Structured.Network where
toShATermLG :: ATermTable -> Network -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: Network
xv = case Network
xv of
Network a :: [LABELED_ONTO_OR_INTPR_REF]
a b :: [SPEC_NAME]
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [LABELED_ONTO_OR_INTPR_REF] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [LABELED_ONTO_OR_INTPR_REF]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [SPEC_NAME] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [SPEC_NAME]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Network" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, Network)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Network" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph
-> Int -> ATermTable -> (ATermTable, [LABELED_ONTO_OR_INTPR_REF])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [LABELED_ONTO_OR_INTPR_REF]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [SPEC_NAME])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [SPEC_NAME]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, [LABELED_ONTO_OR_INTPR_REF] -> [SPEC_NAME] -> Range -> Network
Network [LABELED_ONTO_OR_INTPR_REF]
a' [SPEC_NAME]
b' Range
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, Network)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.Network" ShATerm
u
instance ShATermLG Syntax.AS_Structured.FILTERING where
toShATermLG :: ATermTable -> FILTERING -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: FILTERING
xv = case FILTERING
xv of
FilterBasicSpec a :: Bool
a b :: G_basic_spec
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Bool
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> G_basic_spec -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 G_basic_spec
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "FilterBasicSpec" [Int
a', Int
b', Int
c'] []) ATermTable
att3
FilterSymbolList a :: Bool
a b :: G_symb_items_list
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Bool
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> G_symb_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 G_symb_items_list
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "FilterSymbolList" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, FILTERING)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "FilterBasicSpec" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Bool
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_basic_spec)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: G_basic_spec
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Bool -> G_basic_spec -> Range -> FILTERING
FilterBasicSpec Bool
a' G_basic_spec
b' Range
c') }}}
ShAAppl "FilterSymbolList" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Bool
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_symb_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: G_symb_items_list
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Bool -> G_symb_items_list -> Range -> FILTERING
FilterSymbolList Bool
a' G_symb_items_list
b' Range
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, FILTERING)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.FILTERING" ShATerm
u
instance ShATermLG Syntax.AS_Structured.EXTRACTION where
toShATermLG :: ATermTable -> EXTRACTION -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: EXTRACTION
xv = case EXTRACTION
xv of
ExtractOrRemove a :: Bool
a b :: [SPEC_NAME]
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Bool
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [SPEC_NAME] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [SPEC_NAME]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "ExtractOrRemove" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, EXTRACTION)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "ExtractOrRemove" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Bool
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [SPEC_NAME])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [SPEC_NAME]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Bool -> [SPEC_NAME] -> Range -> EXTRACTION
ExtractOrRemove Bool
a' [SPEC_NAME]
b' Range
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, EXTRACTION)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.EXTRACTION" ShATerm
u
instance ShATermLG Syntax.AS_Structured.APPROXIMATION where
toShATermLG :: ATermTable -> APPROXIMATION -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: APPROXIMATION
xv = case APPROXIMATION
xv of
ForgetOrKeep a :: Bool
a b :: [G_hiding]
b c :: Maybe SPEC_NAME
c d :: Range
d -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Bool
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [G_hiding] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [G_hiding]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Maybe SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Maybe SPEC_NAME
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Range
d
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "ForgetOrKeep" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, APPROXIMATION)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "ForgetOrKeep" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Bool
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [G_hiding])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [G_hiding]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Maybe SPEC_NAME
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Range
d') ->
(ATermTable
att4, Bool -> [G_hiding] -> Maybe SPEC_NAME -> Range -> APPROXIMATION
ForgetOrKeep Bool
a' [G_hiding]
b' Maybe SPEC_NAME
c' Range
d') }}}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, APPROXIMATION)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.APPROXIMATION" ShATerm
u
instance ShATermLG Syntax.AS_Structured.MINIMIZATION where
toShATermLG :: ATermTable -> MINIMIZATION -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: MINIMIZATION
xv = case MINIMIZATION
xv of
Mini a :: Token
a b :: [SPEC_NAME]
b c :: [SPEC_NAME]
c d :: Range
d -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Token -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Token
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [SPEC_NAME] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [SPEC_NAME]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> [SPEC_NAME] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 [SPEC_NAME]
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Range
d
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Mini" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, MINIMIZATION)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Mini" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Token)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Token
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [SPEC_NAME])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [SPEC_NAME]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [SPEC_NAME])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: [SPEC_NAME]
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Range
d') ->
(ATermTable
att4, Token -> [SPEC_NAME] -> [SPEC_NAME] -> Range -> MINIMIZATION
Mini Token
a' [SPEC_NAME]
b' [SPEC_NAME]
c' Range
d') }}}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, MINIMIZATION)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.MINIMIZATION" ShATerm
u
instance ShATermLG Syntax.AS_Structured.RENAMING where
toShATermLG :: ATermTable -> RENAMING -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: RENAMING
xv = case RENAMING
xv of
Renaming a :: [G_mapping]
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [G_mapping] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [G_mapping]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Renaming" [Int
a', Int
b'] []) ATermTable
att2
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, RENAMING)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Renaming" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [G_mapping])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [G_mapping]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, [G_mapping] -> Range -> RENAMING
Renaming [G_mapping]
a' Range
b') }}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, RENAMING)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.RENAMING" ShATerm
u
instance ShATermLG Syntax.AS_Structured.RESTRICTION where
toShATermLG :: ATermTable -> RESTRICTION -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: RESTRICTION
xv = case RESTRICTION
xv of
Hidden a :: [G_hiding]
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [G_hiding] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 [G_hiding]
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Hidden" [Int
a', Int
b'] []) ATermTable
att2
Revealed a :: G_symb_map_items_list
a b :: Range
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> G_symb_map_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 G_symb_map_items_list
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Range
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Revealed" [Int
a', Int
b'] []) ATermTable
att2
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, RESTRICTION)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Hidden" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [G_hiding])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: [G_hiding]
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, [G_hiding] -> Range -> RESTRICTION
Hidden [G_hiding]
a' Range
b') }}
ShAAppl "Revealed" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph
-> Int -> ATermTable -> (ATermTable, G_symb_map_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: G_symb_map_items_list
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Range
b') ->
(ATermTable
att2, G_symb_map_items_list -> Range -> RESTRICTION
Revealed G_symb_map_items_list
a' Range
b') }}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, RESTRICTION)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.RESTRICTION" ShATerm
u
instance ShATermLG Syntax.AS_Structured.G_mapping where
toShATermLG :: ATermTable -> G_mapping -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: G_mapping
xv = case G_mapping
xv of
G_symb_map a :: G_symb_map_items_list
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> G_symb_map_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 G_symb_map_items_list
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "G_symb_map" [Int
a'] []) ATermTable
att1
G_logic_translation a :: Logic_code
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Logic_code -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Logic_code
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "G_logic_translation" [Int
a'] []) ATermTable
att1
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, G_mapping)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "G_symb_map" [a :: Int
a] _ ->
case LogicGraph
-> Int -> ATermTable -> (ATermTable, G_symb_map_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: G_symb_map_items_list
a') ->
(ATermTable
att1, G_symb_map_items_list -> G_mapping
G_symb_map G_symb_map_items_list
a') }
ShAAppl "G_logic_translation" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Logic_code)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Logic_code
a') ->
(ATermTable
att1, Logic_code -> G_mapping
G_logic_translation Logic_code
a') }
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, G_mapping)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.G_mapping" ShATerm
u
instance ShATermLG Syntax.AS_Structured.G_hiding where
toShATermLG :: ATermTable -> G_hiding -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: G_hiding
xv = case G_hiding
xv of
G_symb_list a :: G_symb_items_list
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> G_symb_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 G_symb_items_list
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "G_symb_list" [Int
a'] []) ATermTable
att1
G_logic_projection a :: Logic_code
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Logic_code -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Logic_code
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "G_logic_projection" [Int
a'] []) ATermTable
att1
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, G_hiding)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "G_symb_list" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_symb_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: G_symb_items_list
a') ->
(ATermTable
att1, G_symb_items_list -> G_hiding
G_symb_list G_symb_items_list
a') }
ShAAppl "G_logic_projection" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Logic_code)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Logic_code
a') ->
(ATermTable
att1, Logic_code -> G_hiding
G_logic_projection Logic_code
a') }
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, G_hiding)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.G_hiding" ShATerm
u
instance ShATermLG Syntax.AS_Structured.FIT_ARG where
toShATermLG :: ATermTable -> FIT_ARG -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: FIT_ARG
xv = case FIT_ARG
xv of
Fit_spec a :: Annoted SPEC
a b :: [G_mapping]
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Annoted SPEC -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Annoted SPEC
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [G_mapping] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [G_mapping]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Fit_spec" [Int
a', Int
b', Int
c'] []) ATermTable
att3
Fit_view a :: SPEC_NAME
a b :: [Annoted FIT_ARG]
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> [Annoted FIT_ARG] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 [Annoted FIT_ARG]
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Fit_view" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, FIT_ARG)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Fit_spec" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Annoted SPEC)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Annoted SPEC
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [G_mapping])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [G_mapping]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Annoted SPEC -> [G_mapping] -> Range -> FIT_ARG
Fit_spec Annoted SPEC
a' [G_mapping]
b' Range
c') }}}
ShAAppl "Fit_view" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [Annoted FIT_ARG])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: [Annoted FIT_ARG]
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, SPEC_NAME -> [Annoted FIT_ARG] -> Range -> FIT_ARG
Fit_view SPEC_NAME
a' [Annoted FIT_ARG]
b' Range
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, FIT_ARG)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.FIT_ARG" ShATerm
u
instance ShATermLG Syntax.AS_Structured.LogicDescr where
toShATermLG :: ATermTable -> LogicDescr -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: LogicDescr
xv = case LogicDescr
xv of
LogicDescr a :: Logic_name
a b :: Maybe SPEC_NAME
b c :: Range
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Logic_name -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Logic_name
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Maybe SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Maybe SPEC_NAME
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Range
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "LogicDescr" [Int
a', Int
b', Int
c'] []) ATermTable
att3
SyntaxQual a :: SPEC_NAME
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "SyntaxQual" [Int
a'] []) ATermTable
att1
LanguageQual a :: SPEC_NAME
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "LanguageQual" [Int
a'] []) ATermTable
att1
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, LogicDescr)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "LogicDescr" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Logic_name)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Logic_name
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Maybe SPEC_NAME
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Range
c') ->
(ATermTable
att3, Logic_name -> Maybe SPEC_NAME -> Range -> LogicDescr
LogicDescr Logic_name
a' Maybe SPEC_NAME
b' Range
c') }}}
ShAAppl "SyntaxQual" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
(ATermTable
att1, SPEC_NAME -> LogicDescr
SyntaxQual SPEC_NAME
a') }
ShAAppl "LanguageQual" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
(ATermTable
att1, SPEC_NAME -> LogicDescr
LanguageQual SPEC_NAME
a') }
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, LogicDescr)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.LogicDescr" ShATerm
u
instance ShATermLG Syntax.AS_Structured.Logic_code where
toShATermLG :: ATermTable -> Logic_code -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: Logic_code
xv = case Logic_code
xv of
Logic_code a :: Maybe String
a b :: Maybe Logic_name
b c :: Maybe Logic_name
c d :: Range
d -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Maybe String -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Maybe String
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Maybe Logic_name -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Maybe Logic_name
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Maybe Logic_name -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Maybe Logic_name
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Range
d
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Logic_code" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, Logic_code)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Logic_code" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe String)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Maybe String
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe Logic_name)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Maybe Logic_name
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe Logic_name)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Maybe Logic_name
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Range
d') ->
(ATermTable
att4, Maybe String
-> Maybe Logic_name -> Maybe Logic_name -> Range -> Logic_code
Logic_code Maybe String
a' Maybe Logic_name
b' Maybe Logic_name
c' Range
d') }}}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, Logic_code)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.Logic_code" ShATerm
u
instance ShATermLG Syntax.AS_Structured.Logic_name where
toShATermLG :: ATermTable -> Logic_name -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: Logic_name
xv = case Logic_name
xv of
Logic_name a :: String
a b :: Maybe Token
b c :: Maybe SPEC_NAME
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> String -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 String
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Maybe Token -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Maybe Token
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Maybe SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 Maybe SPEC_NAME
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Logic_name" [Int
a', Int
b', Int
c'] []) ATermTable
att3
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, Logic_name)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Logic_name" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, String)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: String
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe Token)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Maybe Token
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: Maybe SPEC_NAME
c') ->
(ATermTable
att3, String -> Maybe Token -> Maybe SPEC_NAME -> Logic_name
Logic_name String
a' Maybe Token
b' Maybe SPEC_NAME
c') }}}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, Logic_name)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.Logic_name" ShATerm
u
instance ShATermLG Syntax.AS_Structured.LABELED_ONTO_OR_INTPR_REF where
toShATermLG :: ATermTable -> LABELED_ONTO_OR_INTPR_REF -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: LABELED_ONTO_OR_INTPR_REF
xv = case LABELED_ONTO_OR_INTPR_REF
xv of
Labeled a :: Maybe Token
a b :: SPEC_NAME
b -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Maybe Token -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Maybe Token
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 SPEC_NAME
b
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Labeled" [Int
a', Int
b'] []) ATermTable
att2
fromShATermLG :: LogicGraph
-> Int -> ATermTable -> (ATermTable, LABELED_ONTO_OR_INTPR_REF)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Labeled" [a :: Int
a, b :: Int
b] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe Token)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Maybe Token
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: SPEC_NAME
b') ->
(ATermTable
att2, Maybe Token -> SPEC_NAME -> LABELED_ONTO_OR_INTPR_REF
Labeled Maybe Token
a' SPEC_NAME
b') }}
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, LABELED_ONTO_OR_INTPR_REF)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.LABELED_ONTO_OR_INTPR_REF" ShATerm
u
instance ShATermLG Syntax.AS_Structured.CORRESPONDENCE where
toShATermLG :: ATermTable -> CORRESPONDENCE -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: CORRESPONDENCE
xv = case CORRESPONDENCE
xv of
Correspondence_block a :: Maybe RELATION_REF
a b :: Maybe CONFIDENCE
b c :: [CORRESPONDENCE]
c -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Maybe RELATION_REF -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Maybe RELATION_REF
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Maybe CONFIDENCE -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 Maybe CONFIDENCE
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> [CORRESPONDENCE] -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 [CORRESPONDENCE]
c
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Correspondence_block" [Int
a', Int
b',
Int
c'] []) ATermTable
att3
Single_correspondence a :: Maybe Annotation
a b :: G_symb_items_list
b c :: G_symb_items_list
c d :: Maybe RELATION_REF
d e :: Maybe CONFIDENCE
e -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Maybe Annotation -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 Maybe Annotation
a
(att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> G_symb_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att1 G_symb_items_list
b
(att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> G_symb_items_list -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att2 G_symb_items_list
c
(att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Maybe RELATION_REF -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att3 Maybe RELATION_REF
d
(att5 :: ATermTable
att5, e' :: Int
e') <- ATermTable -> Maybe CONFIDENCE -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att4 Maybe CONFIDENCE
e
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Single_correspondence" [Int
a', Int
b', Int
c', Int
d',
Int
e'] []) ATermTable
att5
Default_correspondence ->
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Default_correspondence" [] []) ATermTable
att0
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, CORRESPONDENCE)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Correspondence_block" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe RELATION_REF)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Maybe RELATION_REF
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe CONFIDENCE)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: Maybe CONFIDENCE
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, [CORRESPONDENCE])
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: [CORRESPONDENCE]
c') ->
(ATermTable
att3, Maybe RELATION_REF
-> Maybe CONFIDENCE -> [CORRESPONDENCE] -> CORRESPONDENCE
Correspondence_block Maybe RELATION_REF
a' Maybe CONFIDENCE
b' [CORRESPONDENCE]
c') }}}
ShAAppl "Single_correspondence" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d, e :: Int
e] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe Annotation)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: Maybe Annotation
a') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_symb_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
b ATermTable
att1 of
{ (att2 :: ATermTable
att2, b' :: G_symb_items_list
b') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, G_symb_items_list)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
c ATermTable
att2 of
{ (att3 :: ATermTable
att3, c' :: G_symb_items_list
c') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe RELATION_REF)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
d ATermTable
att3 of
{ (att4 :: ATermTable
att4, d' :: Maybe RELATION_REF
d') ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, Maybe CONFIDENCE)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
e ATermTable
att4 of
{ (att5 :: ATermTable
att5, e' :: Maybe CONFIDENCE
e') ->
(ATermTable
att5, Maybe Annotation
-> G_symb_items_list
-> G_symb_items_list
-> Maybe RELATION_REF
-> Maybe CONFIDENCE
-> CORRESPONDENCE
Single_correspondence Maybe Annotation
a' G_symb_items_list
b' G_symb_items_list
c' Maybe RELATION_REF
d' Maybe CONFIDENCE
e') }}}}}
ShAAppl "Default_correspondence" [] _ -> (ATermTable
att0, CORRESPONDENCE
Default_correspondence)
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, CORRESPONDENCE)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.CORRESPONDENCE" ShATerm
u
instance ShATermLG Syntax.AS_Structured.RELATION_REF where
toShATermLG :: ATermTable -> RELATION_REF -> IO (ATermTable, Int)
toShATermLG att0 :: ATermTable
att0 xv :: RELATION_REF
xv = case RELATION_REF
xv of
Subsumes -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Subsumes" [] []) ATermTable
att0
IsSubsumed -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "IsSubsumed" [] []) ATermTable
att0
Equivalent -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Equivalent" [] []) ATermTable
att0
Incompatible -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Incompatible" [] []) ATermTable
att0
HasInstance -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "HasInstance" [] []) ATermTable
att0
InstanceOf -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "InstanceOf" [] []) ATermTable
att0
DefaultRelation -> (ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "DefaultRelation" [] []) ATermTable
att0
Iri a :: SPEC_NAME
a -> do
(att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SPEC_NAME -> IO (ATermTable, Int)
forall t. ShATermLG t => ATermTable -> t -> IO (ATermTable, Int)
toShATermLG' ATermTable
att0 SPEC_NAME
a
(ATermTable, Int) -> IO (ATermTable, Int)
forall (m :: * -> *) a. Monad m => a -> m a
return ((ATermTable, Int) -> IO (ATermTable, Int))
-> (ATermTable, Int) -> IO (ATermTable, Int)
forall a b. (a -> b) -> a -> b
$ ShATerm -> ATermTable -> (ATermTable, Int)
addATerm (String -> [Int] -> [Int] -> ShATerm
ShAAppl "Iri" [Int
a'] []) ATermTable
att1
fromShATermLG :: LogicGraph -> Int -> ATermTable -> (ATermTable, RELATION_REF)
fromShATermLG lg :: LogicGraph
lg ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
ShAAppl "Subsumes" [] _ -> (ATermTable
att0, RELATION_REF
Subsumes)
ShAAppl "IsSubsumed" [] _ -> (ATermTable
att0, RELATION_REF
IsSubsumed)
ShAAppl "Equivalent" [] _ -> (ATermTable
att0, RELATION_REF
Equivalent)
ShAAppl "Incompatible" [] _ -> (ATermTable
att0, RELATION_REF
Incompatible)
ShAAppl "HasInstance" [] _ -> (ATermTable
att0, RELATION_REF
HasInstance)
ShAAppl "InstanceOf" [] _ -> (ATermTable
att0, RELATION_REF
InstanceOf)
ShAAppl "DefaultRelation" [] _ -> (ATermTable
att0, RELATION_REF
DefaultRelation)
ShAAppl "Iri" [a :: Int
a] _ ->
case LogicGraph -> Int -> ATermTable -> (ATermTable, SPEC_NAME)
forall t.
ShATermLG t =>
LogicGraph -> Int -> ATermTable -> (ATermTable, t)
fromShATermLG' LogicGraph
lg Int
a ATermTable
att0 of
{ (att1 :: ATermTable
att1, a' :: SPEC_NAME
a') ->
(ATermTable
att1, SPEC_NAME -> RELATION_REF
Iri SPEC_NAME
a') }
u :: ShATerm
u -> String -> ShATerm -> (ATermTable, RELATION_REF)
forall a. String -> ShATerm -> a
fromShATermError "Syntax.AS_Structured.RELATION_REF" ShATerm
u