{-# OPTIONS -w -O0 #-}
{-# LANGUAGE CPP, StandaloneDeriving, DeriveDataTypeable, DeriveGeneric #-}
{- |
Module      :  ExtModal/ATC_ExtModal.der.hs
Description :  generated ShATermConvertible, Json instances
Copyright   :  (c) DFKI GmbH 2012
License     :  GPLv2 or higher, see LICENSE.txt

Maintainer  :  Christian.Maeder@dfki.de
Stability   :  provisional
Portability :  non-portable(derive Typeable instances)

Automatic derivation of instances via DrIFT-rule ShATermConvertible, Json
  for the type(s):
'ExtModal.AS_ExtModal.FrameForm'
'ExtModal.AS_ExtModal.ModDefn'
'ExtModal.AS_ExtModal.EM_BASIC_ITEM'
'ExtModal.AS_ExtModal.ModOp'
'ExtModal.AS_ExtModal.MODALITY'
'ExtModal.AS_ExtModal.EM_SIG_ITEM'
'ExtModal.AS_ExtModal.BoxOp'
'ExtModal.AS_ExtModal.FormPrefix'
'ExtModal.AS_ExtModal.EM_FORMULA'
'ExtModal.ExtModalSign.EModalSign'
'ExtModal.MorphismExtension.MorphExtension'
'ExtModal.Sublogic.Frequency'
'ExtModal.Sublogic.Sublogic'
-}

{-
Generated by 'genRules' (automatic rule generation for DrIFT). Don't touch!!
  dependency files:
ExtModal/AS_ExtModal.hs
ExtModal/ExtModalSign.hs
ExtModal/MorphismExtension.hs
ExtModal/Sublogic.hs
-}

module ExtModal.ATC_ExtModal () where

import ATerm.Lib
import CASL.AS_Basic_CASL
import CASL.ATC_CASL
import CASL.MapSentence
import CASL.Morphism
import CASL.Sign
import CASL.Sublogic
import Common.AS_Annotation
import Common.Doc
import Common.DocUtils
import Common.Id
import Common.Json.Instances
import Common.Utils
import Data.Aeson(ToJSON, FromJSON)
import Data.Data
import Data.Function
import Data.List
import ExtModal.AS_ExtModal
import ExtModal.ExtModalSign
import ExtModal.MorphismExtension
import ExtModal.Print_AS ()
import ExtModal.Sublogic
import GHC.Generics(Generic)
import qualified Common.Lib.MapSet as MapSet
import qualified Data.Map as Map
import qualified Data.Set as Set

{-! for ExtModal.AS_ExtModal.FrameForm derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.ModDefn derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.EM_BASIC_ITEM derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.ModOp derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.MODALITY derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.EM_SIG_ITEM derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.BoxOp derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.FormPrefix derive : ShATermConvertible !-}
{-! for ExtModal.AS_ExtModal.EM_FORMULA derive : ShATermConvertible !-}
{-! for ExtModal.ExtModalSign.EModalSign derive : ShATermConvertible !-}
{-! for ExtModal.MorphismExtension.MorphExtension derive : ShATermConvertible !-}
{-! for ExtModal.Sublogic.Frequency derive : ShATermConvertible !-}
{-! for ExtModal.Sublogic.Sublogic derive : ShATermConvertible !-}

{-! for ExtModal.AS_ExtModal.FrameForm derive : Json !-}
{-! for ExtModal.AS_ExtModal.ModDefn derive : Json !-}
{-! for ExtModal.AS_ExtModal.EM_BASIC_ITEM derive : Json !-}
{-! for ExtModal.AS_ExtModal.ModOp derive : Json !-}
{-! for ExtModal.AS_ExtModal.MODALITY derive : Json !-}
{-! for ExtModal.AS_ExtModal.EM_SIG_ITEM derive : Json !-}
{-! for ExtModal.AS_ExtModal.BoxOp derive : Json !-}
{-! for ExtModal.AS_ExtModal.FormPrefix derive : Json !-}
{-! for ExtModal.AS_ExtModal.EM_FORMULA derive : Json !-}
{-! for ExtModal.ExtModalSign.EModalSign derive : Json !-}
{-! for ExtModal.MorphismExtension.MorphExtension derive : Json !-}
{-! for ExtModal.Sublogic.Frequency derive : Json !-}
{-! for ExtModal.Sublogic.Sublogic derive : Json !-}

-- Generated by DrIFT, look but don't touch!

instance ShATermConvertible ExtModal.AS_ExtModal.FrameForm where
  toShATermAux :: ATermTable -> FrameForm -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: FrameForm
xv = case FrameForm
xv of
    FrameForm a :: [VAR_DECL]
a b :: [Annoted (FORMULA EM_FORMULA)]
b c :: Range
c -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [VAR_DECL] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 [VAR_DECL]
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable
-> [Annoted (FORMULA EM_FORMULA)] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 [Annoted (FORMULA EM_FORMULA)]
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "FrameForm" [Int
a', Int
b', Int
c'] []) ATermTable
att3
  fromShATermAux :: Int -> ATermTable -> (ATermTable, FrameForm)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "FrameForm" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
      case Int -> ATermTable -> (ATermTable, [VAR_DECL])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: [VAR_DECL]
a') ->
      case Int -> ATermTable -> (ATermTable, [Annoted (FORMULA EM_FORMULA)])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: [Annoted (FORMULA EM_FORMULA)]
b') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Range
c') ->
      (ATermTable
att3, [VAR_DECL] -> [Annoted (FORMULA EM_FORMULA)] -> Range -> FrameForm
FrameForm [VAR_DECL]
a' [Annoted (FORMULA EM_FORMULA)]
b' Range
c') }}}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, FrameForm)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.FrameForm" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.ModDefn where
  toShATermAux :: ATermTable -> ModDefn -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: ModDefn
xv = case ModDefn
xv of
    ModDefn a :: Bool
a b :: Bool
b c :: [Annoted Id]
c d :: [Annoted FrameForm]
d e :: Range
e -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 Bool
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> [Annoted Id] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 [Annoted Id]
c
      (att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> [Annoted FrameForm] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att3 [Annoted FrameForm]
d
      (att5 :: ATermTable
att5, e' :: Int
e') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "ModDefn" [Int
a', Int
b', Int
c', Int
d', Int
e'] []) ATermTable
att5
  fromShATermAux :: Int -> ATermTable -> (ATermTable, ModDefn)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "ModDefn" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d, e :: Int
e] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: Bool
b') ->
      case Int -> ATermTable -> (ATermTable, [Annoted Id])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: [Annoted Id]
c') ->
      case Int -> ATermTable -> (ATermTable, [Annoted FrameForm])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
d ATermTable
att3 of
      { (att4 :: ATermTable
att4, d' :: [Annoted FrameForm]
d') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
e ATermTable
att4 of
      { (att5 :: ATermTable
att5, e' :: Range
e') ->
      (ATermTable
att5, Bool
-> Bool -> [Annoted Id] -> [Annoted FrameForm] -> Range -> ModDefn
ModDefn Bool
a' Bool
b' [Annoted Id]
c' [Annoted FrameForm]
d' Range
e') }}}}}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, ModDefn)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.ModDefn" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.EM_BASIC_ITEM where
  toShATermAux :: ATermTable -> EM_BASIC_ITEM -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: EM_BASIC_ITEM
xv = case EM_BASIC_ITEM
xv of
    ModItem a :: ModDefn
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> ModDefn -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 ModDefn
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 "ModItem" [Int
a'] []) ATermTable
att1
    Nominal_decl a :: [Annoted SIMPLE_ID]
a b :: Range
b -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> [Annoted SIMPLE_ID] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 [Annoted SIMPLE_ID]
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "Nominal_decl" [Int
a', Int
b'] []) ATermTable
att2
  fromShATermAux :: Int -> ATermTable -> (ATermTable, EM_BASIC_ITEM)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "ModItem" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, ModDefn)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: ModDefn
a') ->
      (ATermTable
att1, ModDefn -> EM_BASIC_ITEM
ModItem ModDefn
a') }
    ShAAppl "Nominal_decl" [a :: Int
a, b :: Int
b] _ ->
      case Int -> ATermTable -> (ATermTable, [Annoted SIMPLE_ID])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: [Annoted SIMPLE_ID]
a') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: Range
b') ->
      (ATermTable
att2, [Annoted SIMPLE_ID] -> Range -> EM_BASIC_ITEM
Nominal_decl [Annoted SIMPLE_ID]
a' Range
b') }}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, EM_BASIC_ITEM)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.EM_BASIC_ITEM" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.ModOp where
  toShATermAux :: ATermTable -> ModOp -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: ModOp
xv = case ModOp
xv of
    Composition -> (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 "Composition" [] []) ATermTable
att0
    Intersection -> (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" [] []) ATermTable
att0
    Union -> (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" [] []) ATermTable
att0
    OrElse -> (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 "OrElse" [] []) ATermTable
att0
  fromShATermAux :: Int -> ATermTable -> (ATermTable, ModOp)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "Composition" [] _ -> (ATermTable
att0, ModOp
Composition)
    ShAAppl "Intersection" [] _ -> (ATermTable
att0, ModOp
Intersection)
    ShAAppl "Union" [] _ -> (ATermTable
att0, ModOp
Union)
    ShAAppl "OrElse" [] _ -> (ATermTable
att0, ModOp
OrElse)
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, ModOp)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.ModOp" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.MODALITY where
  toShATermAux :: ATermTable -> MODALITY -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: MODALITY
xv = case MODALITY
xv of
    SimpleMod a :: SIMPLE_ID
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> SIMPLE_ID -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 SIMPLE_ID
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 "SimpleMod" [Int
a'] []) ATermTable
att1
    TermMod a :: TERM EM_FORMULA
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> TERM EM_FORMULA -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 TERM EM_FORMULA
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 "TermMod" [Int
a'] []) ATermTable
att1
    ModOp a :: ModOp
a b :: MODALITY
b c :: MODALITY
c -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> ModOp -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 ModOp
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> MODALITY -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 MODALITY
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> MODALITY -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 MODALITY
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 "ModOp" [Int
a', Int
b', Int
c'] []) ATermTable
att3
    TransClos a :: MODALITY
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> MODALITY -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 MODALITY
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 "TransClos" [Int
a'] []) ATermTable
att1
    Guard a :: FORMULA EM_FORMULA
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> FORMULA EM_FORMULA -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 FORMULA EM_FORMULA
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 "Guard" [Int
a'] []) ATermTable
att1
  fromShATermAux :: Int -> ATermTable -> (ATermTable, MODALITY)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "SimpleMod" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, SIMPLE_ID)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: SIMPLE_ID
a') ->
      (ATermTable
att1, SIMPLE_ID -> MODALITY
SimpleMod SIMPLE_ID
a') }
    ShAAppl "TermMod" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, TERM EM_FORMULA)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: TERM EM_FORMULA
a') ->
      (ATermTable
att1, TERM EM_FORMULA -> MODALITY
TermMod TERM EM_FORMULA
a') }
    ShAAppl "ModOp" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
      case Int -> ATermTable -> (ATermTable, ModOp)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: ModOp
a') ->
      case Int -> ATermTable -> (ATermTable, MODALITY)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: MODALITY
b') ->
      case Int -> ATermTable -> (ATermTable, MODALITY)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: MODALITY
c') ->
      (ATermTable
att3, ModOp -> MODALITY -> MODALITY -> MODALITY
ModOp ModOp
a' MODALITY
b' MODALITY
c') }}}
    ShAAppl "TransClos" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, MODALITY)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: MODALITY
a') ->
      (ATermTable
att1, MODALITY -> MODALITY
TransClos MODALITY
a') }
    ShAAppl "Guard" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, FORMULA EM_FORMULA)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: FORMULA EM_FORMULA
a') ->
      (ATermTable
att1, FORMULA EM_FORMULA -> MODALITY
Guard FORMULA EM_FORMULA
a') }
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, MODALITY)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.MODALITY" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.EM_SIG_ITEM where
  toShATermAux :: ATermTable -> EM_SIG_ITEM -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: EM_SIG_ITEM
xv = case EM_SIG_ITEM
xv of
    Rigid_op_items a :: Bool
a b :: [Annoted (OP_ITEM EM_FORMULA)]
b c :: Range
c -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable
-> [Annoted (OP_ITEM EM_FORMULA)] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 [Annoted (OP_ITEM EM_FORMULA)]
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "Rigid_op_items" [Int
a', Int
b', Int
c'] []) ATermTable
att3
    Rigid_pred_items a :: Bool
a b :: [Annoted (PRED_ITEM EM_FORMULA)]
b c :: Range
c -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable
-> [Annoted (PRED_ITEM EM_FORMULA)] -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 [Annoted (PRED_ITEM EM_FORMULA)]
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "Rigid_pred_items" [Int
a', Int
b', Int
c'] []) ATermTable
att3
  fromShATermAux :: Int -> ATermTable -> (ATermTable, EM_SIG_ITEM)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "Rigid_op_items" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, [Annoted (OP_ITEM EM_FORMULA)])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: [Annoted (OP_ITEM EM_FORMULA)]
b') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Range
c') ->
      (ATermTable
att3, Bool -> [Annoted (OP_ITEM EM_FORMULA)] -> Range -> EM_SIG_ITEM
Rigid_op_items Bool
a' [Annoted (OP_ITEM EM_FORMULA)]
b' Range
c') }}}
    ShAAppl "Rigid_pred_items" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, [Annoted (PRED_ITEM EM_FORMULA)])
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: [Annoted (PRED_ITEM EM_FORMULA)]
b') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Range
c') ->
      (ATermTable
att3, Bool -> [Annoted (PRED_ITEM EM_FORMULA)] -> Range -> EM_SIG_ITEM
Rigid_pred_items Bool
a' [Annoted (PRED_ITEM EM_FORMULA)]
b' Range
c') }}}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, EM_SIG_ITEM)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.EM_SIG_ITEM" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.BoxOp where
  toShATermAux :: ATermTable -> BoxOp -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: BoxOp
xv = case BoxOp
xv of
    Box -> (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 "Box" [] []) ATermTable
att0
    Diamond -> (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 "Diamond" [] []) ATermTable
att0
    EBox -> (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 "EBox" [] []) ATermTable
att0
  fromShATermAux :: Int -> ATermTable -> (ATermTable, BoxOp)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "Box" [] _ -> (ATermTable
att0, BoxOp
Box)
    ShAAppl "Diamond" [] _ -> (ATermTable
att0, BoxOp
Diamond)
    ShAAppl "EBox" [] _ -> (ATermTable
att0, BoxOp
EBox)
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, BoxOp)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.BoxOp" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.FormPrefix where
  toShATermAux :: ATermTable -> FormPrefix -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: FormPrefix
xv = case FormPrefix
xv of
    BoxOrDiamond a :: BoxOp
a b :: MODALITY
b c :: Bool
c d :: Int
d -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> BoxOp -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 BoxOp
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> MODALITY -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 MODALITY
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 Bool
c
      (att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Int -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att3 Int
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 "BoxOrDiamond" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
    Hybrid a :: Bool
a b :: SIMPLE_ID
b -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> SIMPLE_ID -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 SIMPLE_ID
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 "Hybrid" [Int
a', Int
b'] []) ATermTable
att2
    PathQuantification a :: Bool
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
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 "PathQuantification" [Int
a'] []) ATermTable
att1
    NextY a :: Bool
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
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 "NextY" [Int
a'] []) ATermTable
att1
    StateQuantification a :: Bool
a b :: Bool
b -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 Bool
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 "StateQuantification" [Int
a', Int
b'] []) ATermTable
att2
    FixedPoint a :: Bool
a b :: SIMPLE_ID
b -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> SIMPLE_ID -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 SIMPLE_ID
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 "FixedPoint" [Int
a', Int
b'] []) ATermTable
att2
  fromShATermAux :: Int -> ATermTable -> (ATermTable, FormPrefix)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "BoxOrDiamond" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
      case Int -> ATermTable -> (ATermTable, BoxOp)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: BoxOp
a') ->
      case Int -> ATermTable -> (ATermTable, MODALITY)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: MODALITY
b') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Bool
c') ->
      case Int -> ATermTable -> (ATermTable, Int)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
d ATermTable
att3 of
      { (att4 :: ATermTable
att4, d' :: Int
d') ->
      (ATermTable
att4, BoxOp -> MODALITY -> Bool -> Int -> FormPrefix
BoxOrDiamond BoxOp
a' MODALITY
b' Bool
c' Int
d') }}}}
    ShAAppl "Hybrid" [a :: Int
a, b :: Int
b] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, SIMPLE_ID)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: SIMPLE_ID
b') ->
      (ATermTable
att2, Bool -> SIMPLE_ID -> FormPrefix
Hybrid Bool
a' SIMPLE_ID
b') }}
    ShAAppl "PathQuantification" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      (ATermTable
att1, Bool -> FormPrefix
PathQuantification Bool
a') }
    ShAAppl "NextY" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      (ATermTable
att1, Bool -> FormPrefix
NextY Bool
a') }
    ShAAppl "StateQuantification" [a :: Int
a, b :: Int
b] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: Bool
b') ->
      (ATermTable
att2, Bool -> Bool -> FormPrefix
StateQuantification Bool
a' Bool
b') }}
    ShAAppl "FixedPoint" [a :: Int
a, b :: Int
b] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, SIMPLE_ID)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: SIMPLE_ID
b') ->
      (ATermTable
att2, Bool -> SIMPLE_ID -> FormPrefix
FixedPoint Bool
a' SIMPLE_ID
b') }}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, FormPrefix)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.FormPrefix" ShATerm
u

instance ShATermConvertible ExtModal.AS_ExtModal.EM_FORMULA where
  toShATermAux :: ATermTable -> EM_FORMULA -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: EM_FORMULA
xv = case EM_FORMULA
xv of
    PrefixForm a :: FormPrefix
a b :: FORMULA EM_FORMULA
b c :: Range
c -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> FormPrefix -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 FormPrefix
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> FORMULA EM_FORMULA -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 FORMULA EM_FORMULA
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "PrefixForm" [Int
a', Int
b', Int
c'] []) ATermTable
att3
    UntilSince a :: Bool
a b :: FORMULA EM_FORMULA
b c :: FORMULA EM_FORMULA
c d :: Range
d -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Bool
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> FORMULA EM_FORMULA -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 FORMULA EM_FORMULA
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> FORMULA EM_FORMULA -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 FORMULA EM_FORMULA
c
      (att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Range -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' 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 "UntilSince" [Int
a', Int
b', Int
c', Int
d'] []) ATermTable
att4
    ModForm a :: ModDefn
a -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> ModDefn -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 ModDefn
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 "ModForm" [Int
a'] []) ATermTable
att1
  fromShATermAux :: Int -> ATermTable -> (ATermTable, EM_FORMULA)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "PrefixForm" [a :: Int
a, b :: Int
b, c :: Int
c] _ ->
      case Int -> ATermTable -> (ATermTable, FormPrefix)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: FormPrefix
a') ->
      case Int -> ATermTable -> (ATermTable, FORMULA EM_FORMULA)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: FORMULA EM_FORMULA
b') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Range
c') ->
      (ATermTable
att3, FormPrefix -> FORMULA EM_FORMULA -> Range -> EM_FORMULA
PrefixForm FormPrefix
a' FORMULA EM_FORMULA
b' Range
c') }}}
    ShAAppl "UntilSince" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d] _ ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Bool
a') ->
      case Int -> ATermTable -> (ATermTable, FORMULA EM_FORMULA)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: FORMULA EM_FORMULA
b') ->
      case Int -> ATermTable -> (ATermTable, FORMULA EM_FORMULA)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: FORMULA EM_FORMULA
c') ->
      case Int -> ATermTable -> (ATermTable, Range)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
d ATermTable
att3 of
      { (att4 :: ATermTable
att4, d' :: Range
d') ->
      (ATermTable
att4, Bool
-> FORMULA EM_FORMULA -> FORMULA EM_FORMULA -> Range -> EM_FORMULA
UntilSince Bool
a' FORMULA EM_FORMULA
b' FORMULA EM_FORMULA
c' Range
d') }}}}
    ShAAppl "ModForm" [a :: Int
a] _ ->
      case Int -> ATermTable -> (ATermTable, ModDefn)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: ModDefn
a') ->
      (ATermTable
att1, ModDefn -> EM_FORMULA
ModForm ModDefn
a') }
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, EM_FORMULA)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.AS_ExtModal.EM_FORMULA" ShATerm
u

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.FrameForm
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.FrameForm where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.FrameForm where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.ModDefn
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.ModDefn where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.ModDefn where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.EM_BASIC_ITEM
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.EM_BASIC_ITEM where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.EM_BASIC_ITEM where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.ModOp
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.ModOp where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.ModOp where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.MODALITY
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.MODALITY where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.MODALITY where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.EM_SIG_ITEM
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.EM_SIG_ITEM where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.EM_SIG_ITEM where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.BoxOp
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.BoxOp where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.BoxOp where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.FormPrefix
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.FormPrefix where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.FormPrefix where

deriving instance GHC.Generics.Generic ExtModal.AS_ExtModal.EM_FORMULA
instance Data.Aeson.ToJSON ExtModal.AS_ExtModal.EM_FORMULA where
instance Data.Aeson.FromJSON ExtModal.AS_ExtModal.EM_FORMULA where

deriving instance GHC.Generics.Generic ExtModal.ExtModalSign.EModalSign
instance Data.Aeson.ToJSON ExtModal.ExtModalSign.EModalSign where
instance Data.Aeson.FromJSON ExtModal.ExtModalSign.EModalSign where

instance ShATermConvertible ExtModal.ExtModalSign.EModalSign where
  toShATermAux :: ATermTable -> EModalSign -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: EModalSign
xv = case EModalSign
xv of
    EModalSign a :: OpMap
a b :: PredMap
b c :: Set Id
c d :: Set Id
d e :: Set Id
e f :: Set Id
f -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> OpMap -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 OpMap
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> PredMap -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 PredMap
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Set Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 Set Id
c
      (att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Set Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att3 Set Id
d
      (att5 :: ATermTable
att5, e' :: Int
e') <- ATermTable -> Set Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att4 Set Id
e
      (att6 :: ATermTable
att6, f' :: Int
f') <- ATermTable -> Set Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att5 Set Id
f
      (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 "EModalSign" [Int
a', Int
b', Int
c', Int
d', Int
e',
                                               Int
f'] []) ATermTable
att6
  fromShATermAux :: Int -> ATermTable -> (ATermTable, EModalSign)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "EModalSign" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d, e :: Int
e, f :: Int
f] _ ->
      case Int -> ATermTable -> (ATermTable, OpMap)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: OpMap
a') ->
      case Int -> ATermTable -> (ATermTable, PredMap)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: PredMap
b') ->
      case Int -> ATermTable -> (ATermTable, Set Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Set Id
c') ->
      case Int -> ATermTable -> (ATermTable, Set Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
d ATermTable
att3 of
      { (att4 :: ATermTable
att4, d' :: Set Id
d') ->
      case Int -> ATermTable -> (ATermTable, Set Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
e ATermTable
att4 of
      { (att5 :: ATermTable
att5, e' :: Set Id
e') ->
      case Int -> ATermTable -> (ATermTable, Set Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
f ATermTable
att5 of
      { (att6 :: ATermTable
att6, f' :: Set Id
f') ->
      (ATermTable
att6, OpMap
-> PredMap -> Set Id -> Set Id -> Set Id -> Set Id -> EModalSign
EModalSign OpMap
a' PredMap
b' Set Id
c' Set Id
d' Set Id
e' Set Id
f') }}}}}}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, EModalSign)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.ExtModalSign.EModalSign" ShATerm
u

instance ShATermConvertible ExtModal.MorphismExtension.MorphExtension where
  toShATermAux :: ATermTable -> MorphExtension -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: MorphExtension
xv = case MorphExtension
xv of
    MorphExtension a :: Map Id Id
a b :: Map Id Id
b -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Map Id Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Map Id Id
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Map Id Id -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 Map Id Id
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 "MorphExtension" [Int
a', Int
b'] []) ATermTable
att2
  fromShATermAux :: Int -> ATermTable -> (ATermTable, MorphExtension)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "MorphExtension" [a :: Int
a, b :: Int
b] _ ->
      case Int -> ATermTable -> (ATermTable, Map Id Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Map Id Id
a') ->
      case Int -> ATermTable -> (ATermTable, Map Id Id)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: Map Id Id
b') ->
      (ATermTable
att2, Map Id Id -> Map Id Id -> MorphExtension
MorphExtension Map Id Id
a' Map Id Id
b') }}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, MorphExtension)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.MorphismExtension.MorphExtension" ShATerm
u

deriving instance GHC.Generics.Generic ExtModal.MorphismExtension.MorphExtension
instance Data.Aeson.ToJSON ExtModal.MorphismExtension.MorphExtension where
instance Data.Aeson.FromJSON ExtModal.MorphismExtension.MorphExtension where

instance ShATermConvertible ExtModal.Sublogic.Frequency where
  toShATermAux :: ATermTable -> Frequency -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: Frequency
xv = case Frequency
xv of
    None -> (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 "None" [] []) ATermTable
att0
    One -> (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 "One" [] []) ATermTable
att0
    Many -> (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 "Many" [] []) ATermTable
att0
  fromShATermAux :: Int -> ATermTable -> (ATermTable, Frequency)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "None" [] _ -> (ATermTable
att0, Frequency
None)
    ShAAppl "One" [] _ -> (ATermTable
att0, Frequency
One)
    ShAAppl "Many" [] _ -> (ATermTable
att0, Frequency
Many)
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, Frequency)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.Sublogic.Frequency" ShATerm
u

instance ShATermConvertible ExtModal.Sublogic.Sublogic where
  toShATermAux :: ATermTable -> Sublogic -> IO (ATermTable, Int)
toShATermAux att0 :: ATermTable
att0 xv :: Sublogic
xv = case Sublogic
xv of
    Sublogic a :: Frequency
a b :: Bool
b c :: Bool
c d :: Bool
d e :: Frequency
e f :: Bool
f g :: Bool
g -> do
      (att1 :: ATermTable
att1, a' :: Int
a') <- ATermTable -> Frequency -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att0 Frequency
a
      (att2 :: ATermTable
att2, b' :: Int
b') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att1 Bool
b
      (att3 :: ATermTable
att3, c' :: Int
c') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att2 Bool
c
      (att4 :: ATermTable
att4, d' :: Int
d') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att3 Bool
d
      (att5 :: ATermTable
att5, e' :: Int
e') <- ATermTable -> Frequency -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att4 Frequency
e
      (att6 :: ATermTable
att6, f' :: Int
f') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att5 Bool
f
      (att7 :: ATermTable
att7, g' :: Int
g') <- ATermTable -> Bool -> IO (ATermTable, Int)
forall t.
ShATermConvertible t =>
ATermTable -> t -> IO (ATermTable, Int)
toShATerm' ATermTable
att6 Bool
g
      (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 "Sublogic" [Int
a', Int
b', Int
c', Int
d', Int
e', Int
f',
                                             Int
g'] []) ATermTable
att7
  fromShATermAux :: Int -> ATermTable -> (ATermTable, Sublogic)
fromShATermAux ix :: Int
ix att0 :: ATermTable
att0 = case Int -> ATermTable -> ShATerm
getShATerm Int
ix ATermTable
att0 of
    ShAAppl "Sublogic" [a :: Int
a, b :: Int
b, c :: Int
c, d :: Int
d, e :: Int
e, f :: Int
f, g :: Int
g] _ ->
      case Int -> ATermTable -> (ATermTable, Frequency)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
a ATermTable
att0 of
      { (att1 :: ATermTable
att1, a' :: Frequency
a') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
b ATermTable
att1 of
      { (att2 :: ATermTable
att2, b' :: Bool
b') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
c ATermTable
att2 of
      { (att3 :: ATermTable
att3, c' :: Bool
c') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
d ATermTable
att3 of
      { (att4 :: ATermTable
att4, d' :: Bool
d') ->
      case Int -> ATermTable -> (ATermTable, Frequency)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
e ATermTable
att4 of
      { (att5 :: ATermTable
att5, e' :: Frequency
e') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
f ATermTable
att5 of
      { (att6 :: ATermTable
att6, f' :: Bool
f') ->
      case Int -> ATermTable -> (ATermTable, Bool)
forall t.
ShATermConvertible t =>
Int -> ATermTable -> (ATermTable, t)
fromShATerm' Int
g ATermTable
att6 of
      { (att7 :: ATermTable
att7, g' :: Bool
g') ->
      (ATermTable
att7, Frequency
-> Bool -> Bool -> Bool -> Frequency -> Bool -> Bool -> Sublogic
Sublogic Frequency
a' Bool
b' Bool
c' Bool
d' Frequency
e' Bool
f' Bool
g') }}}}}}}
    u :: ShATerm
u -> String -> ShATerm -> (ATermTable, Sublogic)
forall a. String -> ShATerm -> a
fromShATermError "ExtModal.Sublogic.Sublogic" ShATerm
u

deriving instance GHC.Generics.Generic ExtModal.Sublogic.Frequency
instance Data.Aeson.ToJSON ExtModal.Sublogic.Frequency where
instance Data.Aeson.FromJSON ExtModal.Sublogic.Frequency where

deriving instance GHC.Generics.Generic ExtModal.Sublogic.Sublogic
instance Data.Aeson.ToJSON ExtModal.Sublogic.Sublogic where
instance Data.Aeson.FromJSON ExtModal.Sublogic.Sublogic where