-- UUAGC 0.9.53 (src-ag/Macro.ag)
module Macro where
{-# LINE 4 "src-ag/Macro.ag" #-}

import CommonTypes
{-# LINE 9 "src-generated/Macro.hs" #-}
-- Macro -------------------------------------------------------
{-
   alternatives:
      alternative Macro:
         child con            : {ConstructorIdent}
         child children       : MacroChildren 
      alternative None:
-}
data Macro = Macro (ConstructorIdent) (MacroChildren)
           | None
           deriving ( Int -> Macro -> ShowS
[Macro] -> ShowS
Macro -> String
(Int -> Macro -> ShowS)
-> (Macro -> String) -> ([Macro] -> ShowS) -> Show Macro
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Macro] -> ShowS
$cshowList :: [Macro] -> ShowS
show :: Macro -> String
$cshow :: Macro -> String
showsPrec :: Int -> Macro -> ShowS
$cshowsPrec :: Int -> Macro -> ShowS
Show)
-- MacroChild --------------------------------------------------
{-
   alternatives:
      alternative RuleChild:
         child name           : {Identifier}
         child macro          : Macro 
      alternative ChildChild:
         child name           : {Identifier}
         child child          : {Identifier}
      alternative ValueChild:
         child name           : {Identifier}
         child value          : {String}
-}
data MacroChild = RuleChild (Identifier) (Macro)
                | ChildChild (Identifier) (Identifier)
                | ValueChild (Identifier) (String)
                deriving ( Int -> MacroChild -> ShowS
[MacroChild] -> ShowS
MacroChild -> String
(Int -> MacroChild -> ShowS)
-> (MacroChild -> String)
-> ([MacroChild] -> ShowS)
-> Show MacroChild
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MacroChild] -> ShowS
$cshowList :: [MacroChild] -> ShowS
show :: MacroChild -> String
$cshow :: MacroChild -> String
showsPrec :: Int -> MacroChild -> ShowS
$cshowsPrec :: Int -> MacroChild -> ShowS
Show)
-- MacroChildren -----------------------------------------------
{-
   alternatives:
      alternative Cons:
         child hd             : MacroChild 
         child tl             : MacroChildren 
      alternative Nil:
-}
type MacroChildren = [MacroChild]
-- MaybeMacro --------------------------------------------------
{-
   alternatives:
      alternative Just:
         child just           : Macro 
      alternative Nothing:
-}
type MaybeMacro = Maybe (Macro)