|
Packit |
2cbdf3 |
{-# OPTIONS_GHC -w #-}
|
|
Packit |
2cbdf3 |
{-# OPTIONS -fglasgow-exts -cpp #-}
|
|
Packit |
2cbdf3 |
-- -----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
--
|
|
Packit |
2cbdf3 |
-- Parser.y, part of Alex
|
|
Packit |
2cbdf3 |
--
|
|
Packit |
2cbdf3 |
-- (c) Simon Marlow 2003
|
|
Packit |
2cbdf3 |
--
|
|
Packit |
2cbdf3 |
-- -----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# OPTIONS_GHC -w #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
module Parser ( parse, P ) where
|
|
Packit |
2cbdf3 |
import AbsSyn
|
|
Packit |
2cbdf3 |
import Scan
|
|
Packit |
2cbdf3 |
import CharSet
|
|
Packit |
2cbdf3 |
import ParseMonad hiding ( StartCode )
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
import Data.Char
|
|
Packit |
2cbdf3 |
--import Debug.Trace
|
|
Packit |
2cbdf3 |
import qualified Data.Array as Happy_Data_Array
|
|
Packit |
2cbdf3 |
import qualified GHC.Exts as Happy_GHC_Exts
|
|
Packit |
2cbdf3 |
import Control.Applicative(Applicative(..))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- parser produced by Happy Version 1.19.4
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
newtype HappyAbsSyn = HappyAbsSyn HappyAny
|
|
Packit |
2cbdf3 |
#if __GLASGOW_HASKELL__ >= 607
|
|
Packit |
2cbdf3 |
type HappyAny = Happy_GHC_Exts.Any
|
|
Packit |
2cbdf3 |
#else
|
|
Packit |
2cbdf3 |
type HappyAny = forall a . a
|
|
Packit |
2cbdf3 |
#endif
|
|
Packit |
2cbdf3 |
happyIn4 :: ((Maybe (AlexPosn,Code), [Directive], Scanner, Maybe (AlexPosn,Code))) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn4 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn4 #-}
|
|
Packit |
2cbdf3 |
happyOut4 :: (HappyAbsSyn ) -> ((Maybe (AlexPosn,Code), [Directive], Scanner, Maybe (AlexPosn,Code)))
|
|
Packit |
2cbdf3 |
happyOut4 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut4 #-}
|
|
Packit |
2cbdf3 |
happyIn5 :: (Maybe (AlexPosn,Code)) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn5 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn5 #-}
|
|
Packit |
2cbdf3 |
happyOut5 :: (HappyAbsSyn ) -> (Maybe (AlexPosn,Code))
|
|
Packit |
2cbdf3 |
happyOut5 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut5 #-}
|
|
Packit |
2cbdf3 |
happyIn6 :: ([Directive]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn6 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn6 #-}
|
|
Packit |
2cbdf3 |
happyOut6 :: (HappyAbsSyn ) -> ([Directive])
|
|
Packit |
2cbdf3 |
happyOut6 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut6 #-}
|
|
Packit |
2cbdf3 |
happyIn7 :: (Directive) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn7 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn7 #-}
|
|
Packit |
2cbdf3 |
happyOut7 :: (HappyAbsSyn ) -> (Directive)
|
|
Packit |
2cbdf3 |
happyOut7 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut7 #-}
|
|
Packit |
2cbdf3 |
happyIn8 :: (Encoding) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn8 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn8 #-}
|
|
Packit |
2cbdf3 |
happyOut8 :: (HappyAbsSyn ) -> (Encoding)
|
|
Packit |
2cbdf3 |
happyOut8 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut8 #-}
|
|
Packit |
2cbdf3 |
happyIn9 :: (()) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn9 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn9 #-}
|
|
Packit |
2cbdf3 |
happyOut9 :: (HappyAbsSyn ) -> (())
|
|
Packit |
2cbdf3 |
happyOut9 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut9 #-}
|
|
Packit |
2cbdf3 |
happyIn10 :: (()) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn10 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn10 #-}
|
|
Packit |
2cbdf3 |
happyOut10 :: (HappyAbsSyn ) -> (())
|
|
Packit |
2cbdf3 |
happyOut10 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut10 #-}
|
|
Packit |
2cbdf3 |
happyIn11 :: (Scanner) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn11 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn11 #-}
|
|
Packit |
2cbdf3 |
happyOut11 :: (HappyAbsSyn ) -> (Scanner)
|
|
Packit |
2cbdf3 |
happyOut11 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut11 #-}
|
|
Packit |
2cbdf3 |
happyIn12 :: ([RECtx]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn12 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn12 #-}
|
|
Packit |
2cbdf3 |
happyOut12 :: (HappyAbsSyn ) -> ([RECtx])
|
|
Packit |
2cbdf3 |
happyOut12 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut12 #-}
|
|
Packit |
2cbdf3 |
happyIn13 :: ([RECtx]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn13 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn13 #-}
|
|
Packit |
2cbdf3 |
happyOut13 :: (HappyAbsSyn ) -> ([RECtx])
|
|
Packit |
2cbdf3 |
happyOut13 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut13 #-}
|
|
Packit |
2cbdf3 |
happyIn14 :: (RECtx) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn14 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn14 #-}
|
|
Packit |
2cbdf3 |
happyOut14 :: (HappyAbsSyn ) -> (RECtx)
|
|
Packit |
2cbdf3 |
happyOut14 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut14 #-}
|
|
Packit |
2cbdf3 |
happyIn15 :: ([RECtx]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn15 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn15 #-}
|
|
Packit |
2cbdf3 |
happyOut15 :: (HappyAbsSyn ) -> ([RECtx])
|
|
Packit |
2cbdf3 |
happyOut15 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut15 #-}
|
|
Packit |
2cbdf3 |
happyIn16 :: ([(String,StartCode)]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn16 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn16 #-}
|
|
Packit |
2cbdf3 |
happyOut16 :: (HappyAbsSyn ) -> ([(String,StartCode)])
|
|
Packit |
2cbdf3 |
happyOut16 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut16 #-}
|
|
Packit |
2cbdf3 |
happyIn17 :: ([(String,StartCode)]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn17 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn17 #-}
|
|
Packit |
2cbdf3 |
happyOut17 :: (HappyAbsSyn ) -> ([(String,StartCode)])
|
|
Packit |
2cbdf3 |
happyOut17 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut17 #-}
|
|
Packit |
2cbdf3 |
happyIn18 :: (String) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn18 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn18 #-}
|
|
Packit |
2cbdf3 |
happyOut18 :: (HappyAbsSyn ) -> (String)
|
|
Packit |
2cbdf3 |
happyOut18 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut18 #-}
|
|
Packit |
2cbdf3 |
happyIn19 :: (Maybe Code) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn19 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn19 #-}
|
|
Packit |
2cbdf3 |
happyOut19 :: (HappyAbsSyn ) -> (Maybe Code)
|
|
Packit |
2cbdf3 |
happyOut19 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut19 #-}
|
|
Packit |
2cbdf3 |
happyIn20 :: (Maybe CharSet, RExp, RightContext RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn20 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn20 #-}
|
|
Packit |
2cbdf3 |
happyOut20 :: (HappyAbsSyn ) -> (Maybe CharSet, RExp, RightContext RExp)
|
|
Packit |
2cbdf3 |
happyOut20 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut20 #-}
|
|
Packit |
2cbdf3 |
happyIn21 :: (CharSet) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn21 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn21 #-}
|
|
Packit |
2cbdf3 |
happyOut21 :: (HappyAbsSyn ) -> (CharSet)
|
|
Packit |
2cbdf3 |
happyOut21 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut21 #-}
|
|
Packit |
2cbdf3 |
happyIn22 :: (RightContext RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn22 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn22 #-}
|
|
Packit |
2cbdf3 |
happyOut22 :: (HappyAbsSyn ) -> (RightContext RExp)
|
|
Packit |
2cbdf3 |
happyOut22 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut22 #-}
|
|
Packit |
2cbdf3 |
happyIn23 :: (RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn23 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn23 #-}
|
|
Packit |
2cbdf3 |
happyOut23 :: (HappyAbsSyn ) -> (RExp)
|
|
Packit |
2cbdf3 |
happyOut23 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut23 #-}
|
|
Packit |
2cbdf3 |
happyIn24 :: (RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn24 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn24 #-}
|
|
Packit |
2cbdf3 |
happyOut24 :: (HappyAbsSyn ) -> (RExp)
|
|
Packit |
2cbdf3 |
happyOut24 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut24 #-}
|
|
Packit |
2cbdf3 |
happyIn25 :: (RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn25 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn25 #-}
|
|
Packit |
2cbdf3 |
happyOut25 :: (HappyAbsSyn ) -> (RExp)
|
|
Packit |
2cbdf3 |
happyOut25 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut25 #-}
|
|
Packit |
2cbdf3 |
happyIn26 :: (RExp -> RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn26 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn26 #-}
|
|
Packit |
2cbdf3 |
happyOut26 :: (HappyAbsSyn ) -> (RExp -> RExp)
|
|
Packit |
2cbdf3 |
happyOut26 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut26 #-}
|
|
Packit |
2cbdf3 |
happyIn27 :: (RExp) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn27 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn27 #-}
|
|
Packit |
2cbdf3 |
happyOut27 :: (HappyAbsSyn ) -> (RExp)
|
|
Packit |
2cbdf3 |
happyOut27 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut27 #-}
|
|
Packit |
2cbdf3 |
happyIn28 :: (CharSet) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn28 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn28 #-}
|
|
Packit |
2cbdf3 |
happyOut28 :: (HappyAbsSyn ) -> (CharSet)
|
|
Packit |
2cbdf3 |
happyOut28 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut28 #-}
|
|
Packit |
2cbdf3 |
happyIn29 :: (CharSet) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn29 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn29 #-}
|
|
Packit |
2cbdf3 |
happyOut29 :: (HappyAbsSyn ) -> (CharSet)
|
|
Packit |
2cbdf3 |
happyOut29 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut29 #-}
|
|
Packit |
2cbdf3 |
happyIn30 :: ([CharSet]) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn30 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn30 #-}
|
|
Packit |
2cbdf3 |
happyOut30 :: (HappyAbsSyn ) -> ([CharSet])
|
|
Packit |
2cbdf3 |
happyOut30 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut30 #-}
|
|
Packit |
2cbdf3 |
happyIn31 :: ((AlexPosn,String)) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyIn31 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyIn31 #-}
|
|
Packit |
2cbdf3 |
happyOut31 :: (HappyAbsSyn ) -> ((AlexPosn,String))
|
|
Packit |
2cbdf3 |
happyOut31 x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOut31 #-}
|
|
Packit |
2cbdf3 |
happyInTok :: (Token) -> (HappyAbsSyn )
|
|
Packit |
2cbdf3 |
happyInTok x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyInTok #-}
|
|
Packit |
2cbdf3 |
happyOutTok :: (HappyAbsSyn ) -> (Token)
|
|
Packit |
2cbdf3 |
happyOutTok x = Happy_GHC_Exts.unsafeCoerce# x
|
|
Packit |
2cbdf3 |
{-# INLINE happyOutTok #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyActOffsets :: HappyAddr
|
|
Packit |
2cbdf3 |
happyActOffsets = HappyA# "\x7e\x00\x7e\x00\xfe\x00\x00\x00\x6e\x00\x51\x00\xfe\x00\x7a\x00\x75\x00\x70\x00\x6f\x00\x67\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x63\x00\x51\x00\x7b\x00\x6d\x00\x00\x00\x5b\x00\x00\x00\x1f\x01\x66\x00\x00\x00\x00\x00\x00\x00\x49\x00\x7b\x00\x80\x00\x00\x00\x68\x00\x00\x00\x00\x00\x64\x00\x00\x00\x52\x00\x13\x00\x00\x00\x13\x00\x00\x00\x01\x00\xff\xff\x6d\x00\x02\x00\x10\x00\x12\x00\x00\x00\x00\x00\x7b\x00\x56\x00\x73\x00\x54\x00\x7b\x00\x00\x00\x55\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x44\x00\x00\x00\x6d\x00\x00\x00\x15\x00\x00\x00\x42\x00\x00\x00\x00\x00\x00\x00\x00\x00\x5d\x00\x46\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x37\x00\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x25\x00\x00\x00\x25\x00\x4e\x00\x00\x00\x00\x00\x00\x00\x12\x00\x00\x00\x00\x00\xf7\xff\x00\x00\x00\x00\x4c\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyGotoOffsets :: HappyAddr
|
|
Packit |
2cbdf3 |
happyGotoOffsets = HappyA# "\x69\x00\x47\x00\x4d\x00\x00\x00\x00\x00\x58\x00\x4a\x00\x00\x00\x2d\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x3f\x00\x0a\x00\x1b\x00\xfd\x00\x00\x00\x02\x01\x00\x00\x24\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf4\x00\x2a\x00\x0b\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x21\x00\xa9\x00\x00\x00\x95\x00\x00\x00\xd9\x00\xf5\xff\xeb\x00\x17\x00\x00\x00\x31\x00\x00\x00\x00\x00\x22\x00\x00\x00\xc1\x00\x00\x00\xaf\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xe2\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf2\xff\x09\x00\x00\x00\x00\x00\x00\x00\x00\x00\xcd\x00\x00\x00\xbb\x00\x00\x00\x00\x00\x00\x00\x00\x00\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyDefActions :: HappyAddr
|
|
Packit |
2cbdf3 |
happyDefActions = HappyA# "\xfc\xff\x00\x00\xfa\xff\xfd\xff\x00\x00\xf2\xff\xfa\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf5\xff\xf6\xff\xf7\xff\xf8\xff\xf4\xff\xf9\xff\xfb\xff\x00\x00\xf2\xff\x00\x00\x00\x00\xf0\xff\xd6\xff\xd4\xff\xd2\xff\xc8\xff\xc5\xff\xc2\xff\xbc\xff\x00\x00\x00\x00\xbd\xff\xca\xff\xc4\xff\xbb\xff\xc9\xff\xf1\xff\xf3\xff\xfc\xff\xed\xff\xef\xff\xed\xff\xea\xff\x00\x00\x00\x00\x00\x00\xd8\xff\xc8\xff\x00\x00\xdd\xff\xfe\xff\x00\x00\x00\x00\xbd\xff\x00\x00\xbd\xff\xbf\xff\x00\x00\xcb\xff\xd3\xff\xd1\xff\xd0\xff\xcf\xff\x00\x00\xd5\xff\x00\x00\xd7\xff\x00\x00\xc7\xff\x00\x00\xc1\xff\xbe\xff\xc3\xff\xc6\xff\x00\x00\xe4\xff\xe3\xff\xe2\xff\xdc\xff\xde\xff\xdb\xff\x00\x00\xd8\xff\xe9\xff\xe0\xff\xe1\xff\xec\xff\xe7\xff\xee\xff\xe7\xff\x00\x00\xdf\xff\xda\xff\xd9\xff\x00\x00\xe6\xff\xc0\xff\x00\x00\xce\xff\xcd\xff\x00\x00\xe5\xff\xeb\xff\xe8\xff\xcc\xff"#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyCheck :: HappyAddr
|
|
Packit |
2cbdf3 |
happyCheck = HappyA# "\xff\xff\x02\x00\x01\x00\x0c\x00\x0f\x00\x13\x00\x14\x00\x15\x00\x06\x00\x17\x00\x18\x00\x19\x00\x0b\x00\x1b\x00\x0d\x00\x05\x00\x06\x00\x10\x00\x1b\x00\x12\x00\x01\x00\x14\x00\x03\x00\x15\x00\x17\x00\x1a\x00\x05\x00\x12\x00\x1b\x00\x1c\x00\x1d\x00\x0f\x00\x0d\x00\x0c\x00\x01\x00\x10\x00\x14\x00\x12\x00\x01\x00\x14\x00\x16\x00\x12\x00\x17\x00\x19\x00\x0d\x00\x0e\x00\x1b\x00\x1c\x00\x1d\x00\x04\x00\x0d\x00\x18\x00\x19\x00\x10\x00\x1b\x00\x12\x00\x01\x00\x14\x00\x16\x00\x19\x00\x17\x00\x1b\x00\x0d\x00\x0e\x00\x1b\x00\x1c\x00\x1d\x00\x19\x00\x0d\x00\x1b\x00\x07\x00\x10\x00\x01\x00\x12\x00\x01\x00\x05\x00\x02\x00\x03\x00\x17\x00\x02\x00\x03\x00\x1a\x00\x1b\x00\x1c\x00\x1d\x00\x13\x00\x0d\x00\x0e\x00\x0c\x00\x10\x00\x0c\x00\x12\x00\x01\x00\x05\x00\x06\x00\x1b\x00\x17\x00\x04\x00\x07\x00\x0e\x00\x1b\x00\x1c\x00\x1d\x00\x13\x00\x0d\x00\x00\x00\x01\x00\x10\x00\x1a\x00\x12\x00\x01\x00\x1e\x00\x1f\x00\x1b\x00\x17\x00\x0f\x00\x01\x00\x0f\x00\x1b\x00\x1c\x00\x1d\x00\x11\x00\x0d\x00\x18\x00\x01\x00\x10\x00\x17\x00\x12\x00\xff\xff\x01\x00\x0f\x00\x10\x00\x17\x00\x12\x00\x17\x00\x17\x00\x1b\x00\x1c\x00\x1d\x00\x10\x00\x17\x00\x12\x00\x1b\x00\x1c\x00\x10\x00\x17\x00\x12\x00\x25\x00\x14\x00\xff\xff\x1b\x00\x1c\x00\x1a\x00\xff\xff\xff\xff\x1b\x00\x1c\x00\x08\x00\x09\x00\x0a\x00\xff\xff\x0c\x00\xff\xff\xff\xff\xff\xff\x10\x00\x11\x00\xff\xff\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x08\x00\x09\x00\x0a\x00\xff\xff\x0c\x00\xff\xff\xff\xff\xff\xff\x10\x00\x11\x00\xff\xff\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x0a\x00\x0b\x00\x18\x00\x19\x00\x1a\x00\x1b\x00\x10\x00\x11\x00\xff\xff\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x0a\x00\x0b\x00\x18\x00\x19\x00\x1a\x00\x1b\x00\x10\x00\x11\x00\xff\xff\x13\x00\x14\x00\x15\x00\x0a\x00\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x10\x00\x11\x00\xff\xff\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x13\x00\x14\x00\x15\x00\xff\xff\x17\x00\x18\x00\x19\x00\x15\x00\x1b\x00\x17\x00\x18\x00\x19\x00\xff\xff\x1b\x00\x20\x00\x21\x00\x22\x00\x23\x00\x24\x00\x18\x00\x19\x00\x1a\x00\x1b\x00\x08\x00\x09\x00\x0a\x00\x0b\x00\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff"#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyTable :: HappyAddr
|
|
Packit |
2cbdf3 |
happyTable = HappyA# "\x00\x00\x57\x00\x1f\x00\x66\x00\x55\x00\x5e\x00\x18\x00\x19\x00\x53\x00\x1a\x00\x1b\x00\x1c\x00\x5a\x00\x1d\x00\x20\x00\x27\x00\x14\x00\x21\x00\x67\x00\x22\x00\x1f\x00\x34\x00\x33\x00\x54\x00\x23\x00\x58\x00\x64\x00\x5d\x00\x24\x00\x25\x00\x26\x00\x36\x00\x20\x00\x65\x00\x34\x00\x21\x00\x51\x00\x22\x00\x1f\x00\x34\x00\x4f\x00\x51\x00\x23\x00\x50\x00\x67\x00\x4d\x00\x24\x00\x25\x00\x26\x00\x0f\x00\x20\x00\x26\x00\x1c\x00\x21\x00\x1d\x00\x22\x00\x1f\x00\x34\x00\x3d\x00\x4b\x00\x23\x00\x1d\x00\x4c\x00\x4d\x00\x24\x00\x25\x00\x26\x00\x3a\x00\x20\x00\x1d\x00\x28\x00\x21\x00\x02\x00\x22\x00\x1f\x00\x61\x00\x12\x00\x06\x00\x23\x00\x05\x00\x06\x00\x60\x00\x24\x00\x25\x00\x26\x00\x63\x00\x20\x00\x3d\x00\x6b\x00\x21\x00\x69\x00\x22\x00\x1f\x00\x13\x00\x14\x00\x46\x00\x23\x00\x62\x00\x44\x00\x47\x00\x24\x00\x25\x00\x26\x00\x49\x00\x20\x00\x04\x00\x02\x00\x21\x00\x04\x00\x22\x00\x1f\x00\x16\x00\x17\x00\x4b\x00\x23\x00\x36\x00\x1f\x00\x36\x00\x24\x00\x25\x00\x26\x00\x37\x00\x20\x00\x2a\x00\x1f\x00\x21\x00\x0d\x00\x22\x00\x00\x00\x1f\x00\x36\x00\x21\x00\x23\x00\x22\x00\x0e\x00\x0f\x00\x24\x00\x25\x00\x26\x00\x21\x00\x11\x00\x22\x00\x24\x00\x25\x00\x21\x00\x12\x00\x22\x00\xff\xff\x3a\x00\x00\x00\x24\x00\x25\x00\x04\x00\x00\x00\x00\x00\x24\x00\x25\x00\x5a\x00\x2b\x00\x2c\x00\x00\x00\x2d\x00\x00\x00\x00\x00\x00\x00\x2e\x00\x2f\x00\x00\x00\x30\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x31\x00\x1c\x00\x00\x00\x1d\x00\x2a\x00\x2b\x00\x2c\x00\x00\x00\x2d\x00\x00\x00\x00\x00\x00\x00\x2e\x00\x2f\x00\x00\x00\x30\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x31\x00\x1c\x00\x00\x00\x1d\x00\x5b\x00\x69\x00\x37\x00\x1c\x00\x47\x00\x1d\x00\x2e\x00\x2f\x00\x00\x00\x30\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x31\x00\x1c\x00\x00\x00\x1d\x00\x5b\x00\x5c\x00\x37\x00\x1c\x00\x49\x00\x1d\x00\x2e\x00\x2f\x00\x00\x00\x30\x00\x18\x00\x19\x00\x58\x00\x1a\x00\x31\x00\x1c\x00\x00\x00\x1d\x00\x2e\x00\x2f\x00\x00\x00\x30\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x31\x00\x1c\x00\x00\x00\x1d\x00\x44\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x1b\x00\x1c\x00\x00\x00\x1d\x00\x54\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x1b\x00\x1c\x00\x00\x00\x1d\x00\x3b\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x1b\x00\x1c\x00\x00\x00\x1d\x00\x17\x00\x18\x00\x19\x00\x00\x00\x1a\x00\x1b\x00\x1c\x00\x42\x00\x1d\x00\x1a\x00\x1b\x00\x1c\x00\x00\x00\x1d\x00\x08\x00\x09\x00\x0a\x00\x0b\x00\x0c\x00\x37\x00\x1c\x00\x38\x00\x1d\x00\x3f\x00\x40\x00\x41\x00\x42\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduceArr = Happy_Data_Array.array (1, 68) [
|
|
Packit |
2cbdf3 |
(1 , happyReduce_1),
|
|
Packit |
2cbdf3 |
(2 , happyReduce_2),
|
|
Packit |
2cbdf3 |
(3 , happyReduce_3),
|
|
Packit |
2cbdf3 |
(4 , happyReduce_4),
|
|
Packit |
2cbdf3 |
(5 , happyReduce_5),
|
|
Packit |
2cbdf3 |
(6 , happyReduce_6),
|
|
Packit |
2cbdf3 |
(7 , happyReduce_7),
|
|
Packit |
2cbdf3 |
(8 , happyReduce_8),
|
|
Packit |
2cbdf3 |
(9 , happyReduce_9),
|
|
Packit |
2cbdf3 |
(10 , happyReduce_10),
|
|
Packit |
2cbdf3 |
(11 , happyReduce_11),
|
|
Packit |
2cbdf3 |
(12 , happyReduce_12),
|
|
Packit |
2cbdf3 |
(13 , happyReduce_13),
|
|
Packit |
2cbdf3 |
(14 , happyReduce_14),
|
|
Packit |
2cbdf3 |
(15 , happyReduce_15),
|
|
Packit |
2cbdf3 |
(16 , happyReduce_16),
|
|
Packit |
2cbdf3 |
(17 , happyReduce_17),
|
|
Packit |
2cbdf3 |
(18 , happyReduce_18),
|
|
Packit |
2cbdf3 |
(19 , happyReduce_19),
|
|
Packit |
2cbdf3 |
(20 , happyReduce_20),
|
|
Packit |
2cbdf3 |
(21 , happyReduce_21),
|
|
Packit |
2cbdf3 |
(22 , happyReduce_22),
|
|
Packit |
2cbdf3 |
(23 , happyReduce_23),
|
|
Packit |
2cbdf3 |
(24 , happyReduce_24),
|
|
Packit |
2cbdf3 |
(25 , happyReduce_25),
|
|
Packit |
2cbdf3 |
(26 , happyReduce_26),
|
|
Packit |
2cbdf3 |
(27 , happyReduce_27),
|
|
Packit |
2cbdf3 |
(28 , happyReduce_28),
|
|
Packit |
2cbdf3 |
(29 , happyReduce_29),
|
|
Packit |
2cbdf3 |
(30 , happyReduce_30),
|
|
Packit |
2cbdf3 |
(31 , happyReduce_31),
|
|
Packit |
2cbdf3 |
(32 , happyReduce_32),
|
|
Packit |
2cbdf3 |
(33 , happyReduce_33),
|
|
Packit |
2cbdf3 |
(34 , happyReduce_34),
|
|
Packit |
2cbdf3 |
(35 , happyReduce_35),
|
|
Packit |
2cbdf3 |
(36 , happyReduce_36),
|
|
Packit |
2cbdf3 |
(37 , happyReduce_37),
|
|
Packit |
2cbdf3 |
(38 , happyReduce_38),
|
|
Packit |
2cbdf3 |
(39 , happyReduce_39),
|
|
Packit |
2cbdf3 |
(40 , happyReduce_40),
|
|
Packit |
2cbdf3 |
(41 , happyReduce_41),
|
|
Packit |
2cbdf3 |
(42 , happyReduce_42),
|
|
Packit |
2cbdf3 |
(43 , happyReduce_43),
|
|
Packit |
2cbdf3 |
(44 , happyReduce_44),
|
|
Packit |
2cbdf3 |
(45 , happyReduce_45),
|
|
Packit |
2cbdf3 |
(46 , happyReduce_46),
|
|
Packit |
2cbdf3 |
(47 , happyReduce_47),
|
|
Packit |
2cbdf3 |
(48 , happyReduce_48),
|
|
Packit |
2cbdf3 |
(49 , happyReduce_49),
|
|
Packit |
2cbdf3 |
(50 , happyReduce_50),
|
|
Packit |
2cbdf3 |
(51 , happyReduce_51),
|
|
Packit |
2cbdf3 |
(52 , happyReduce_52),
|
|
Packit |
2cbdf3 |
(53 , happyReduce_53),
|
|
Packit |
2cbdf3 |
(54 , happyReduce_54),
|
|
Packit |
2cbdf3 |
(55 , happyReduce_55),
|
|
Packit |
2cbdf3 |
(56 , happyReduce_56),
|
|
Packit |
2cbdf3 |
(57 , happyReduce_57),
|
|
Packit |
2cbdf3 |
(58 , happyReduce_58),
|
|
Packit |
2cbdf3 |
(59 , happyReduce_59),
|
|
Packit |
2cbdf3 |
(60 , happyReduce_60),
|
|
Packit |
2cbdf3 |
(61 , happyReduce_61),
|
|
Packit |
2cbdf3 |
(62 , happyReduce_62),
|
|
Packit |
2cbdf3 |
(63 , happyReduce_63),
|
|
Packit |
2cbdf3 |
(64 , happyReduce_64),
|
|
Packit |
2cbdf3 |
(65 , happyReduce_65),
|
|
Packit |
2cbdf3 |
(66 , happyReduce_66),
|
|
Packit |
2cbdf3 |
(67 , happyReduce_67),
|
|
Packit |
2cbdf3 |
(68 , happyReduce_68)
|
|
Packit |
2cbdf3 |
]
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happy_n_terms = 38 :: Int
|
|
Packit |
2cbdf3 |
happy_n_nonterms = 28 :: Int
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_1 = happyReduce 5# 0# happyReduction_1
|
|
Packit |
2cbdf3 |
happyReduction_1 (happy_x_5 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_4 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_3 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest)
|
|
Packit |
2cbdf3 |
= case happyOut5 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut6 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
case happyOut11 happy_x_4 of { happy_var_4 ->
|
|
Packit |
2cbdf3 |
case happyOut5 happy_x_5 of { happy_var_5 ->
|
|
Packit |
2cbdf3 |
happyIn4
|
|
Packit |
2cbdf3 |
((happy_var_1,happy_var_2,happy_var_4,happy_var_5)
|
|
Packit |
2cbdf3 |
) `HappyStk` happyRest}}}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_2 = happySpecReduce_1 1# happyReduction_2
|
|
Packit |
2cbdf3 |
happyReduction_2 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn5
|
|
Packit |
2cbdf3 |
(case happy_var_1 of T pos (CodeT code) ->
|
|
Packit |
2cbdf3 |
Just (pos,code)
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_3 = happySpecReduce_0 1# happyReduction_3
|
|
Packit |
2cbdf3 |
happyReduction_3 = happyIn5
|
|
Packit |
2cbdf3 |
(Nothing
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_4 = happySpecReduce_2 2# happyReduction_4
|
|
Packit |
2cbdf3 |
happyReduction_4 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut7 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut6 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn6
|
|
Packit |
2cbdf3 |
(happy_var_1 : happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_5 = happySpecReduce_0 2# happyReduction_5
|
|
Packit |
2cbdf3 |
happyReduction_5 = happyIn6
|
|
Packit |
2cbdf3 |
([]
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_6 = happySpecReduce_2 3# happyReduction_6
|
|
Packit |
2cbdf3 |
happyReduction_6 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (StringT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn7
|
|
Packit |
2cbdf3 |
(WrapperDirective happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_7 = happySpecReduce_2 3# happyReduction_7
|
|
Packit |
2cbdf3 |
happyReduction_7 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut8 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn7
|
|
Packit |
2cbdf3 |
(EncodingDirective happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_8 = happySpecReduce_2 3# happyReduction_8
|
|
Packit |
2cbdf3 |
happyReduction_8 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (StringT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn7
|
|
Packit |
2cbdf3 |
(ActionType happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_9 = happySpecReduce_2 3# happyReduction_9
|
|
Packit |
2cbdf3 |
happyReduction_9 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (StringT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn7
|
|
Packit |
2cbdf3 |
(TokenType happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_10 = happySpecReduce_2 3# happyReduction_10
|
|
Packit |
2cbdf3 |
happyReduction_10 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (StringT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn7
|
|
Packit |
2cbdf3 |
(TypeClass happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_11 = happyMonadReduce 1# 4# happyReduction_11
|
|
Packit |
2cbdf3 |
happyReduction_11 (happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { (T _ (StringT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
( lookupEncoding happy_var_1)}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn8 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_12 = happySpecReduce_2 5# happyReduction_12
|
|
Packit |
2cbdf3 |
happyReduction_12 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn9
|
|
Packit |
2cbdf3 |
(()
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_13 = happySpecReduce_0 5# happyReduction_13
|
|
Packit |
2cbdf3 |
happyReduction_13 = happyIn9
|
|
Packit |
2cbdf3 |
(()
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_14 = happyMonadReduce 2# 6# happyReduction_14
|
|
Packit |
2cbdf3 |
happyReduction_14 (happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { (T _ (SMacDefT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
case happyOut28 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
( newSMac happy_var_1 happy_var_2)}}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn10 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_15 = happyMonadReduce 2# 6# happyReduction_15
|
|
Packit |
2cbdf3 |
happyReduction_15 (happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { (T _ (RMacDefT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
case happyOut23 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
( newRMac happy_var_1 happy_var_2)}}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn10 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_16 = happySpecReduce_2 7# happyReduction_16
|
|
Packit |
2cbdf3 |
happyReduction_16 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { (T _ (BindT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
case happyOut12 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn11
|
|
Packit |
2cbdf3 |
(Scanner happy_var_1 happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_17 = happySpecReduce_2 8# happyReduction_17
|
|
Packit |
2cbdf3 |
happyReduction_17 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut13 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut12 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn12
|
|
Packit |
2cbdf3 |
(happy_var_1 ++ happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_18 = happySpecReduce_0 8# happyReduction_18
|
|
Packit |
2cbdf3 |
happyReduction_18 = happyIn12
|
|
Packit |
2cbdf3 |
([]
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_19 = happySpecReduce_2 9# happyReduction_19
|
|
Packit |
2cbdf3 |
happyReduction_19 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut16 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut14 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn13
|
|
Packit |
2cbdf3 |
([ replaceCodes happy_var_1 happy_var_2 ]
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_20 = happyReduce 4# 9# happyReduction_20
|
|
Packit |
2cbdf3 |
happyReduction_20 (happy_x_4 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_3 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest)
|
|
Packit |
2cbdf3 |
= case happyOut16 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut15 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
happyIn13
|
|
Packit |
2cbdf3 |
(map (replaceCodes happy_var_1) happy_var_3
|
|
Packit |
2cbdf3 |
) `HappyStk` happyRest}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_21 = happySpecReduce_1 9# happyReduction_21
|
|
Packit |
2cbdf3 |
happyReduction_21 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut14 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn13
|
|
Packit |
2cbdf3 |
([ happy_var_1 ]
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_22 = happySpecReduce_2 10# happyReduction_22
|
|
Packit |
2cbdf3 |
happyReduction_22 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut20 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut19 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn14
|
|
Packit |
2cbdf3 |
(let (l,e,r) = happy_var_1 in
|
|
Packit |
2cbdf3 |
RECtx [] l e r happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_23 = happySpecReduce_2 11# happyReduction_23
|
|
Packit |
2cbdf3 |
happyReduction_23 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut14 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut15 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn15
|
|
Packit |
2cbdf3 |
(happy_var_1 : happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_24 = happySpecReduce_0 11# happyReduction_24
|
|
Packit |
2cbdf3 |
happyReduction_24 = happyIn15
|
|
Packit |
2cbdf3 |
([]
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_25 = happySpecReduce_3 12# happyReduction_25
|
|
Packit |
2cbdf3 |
happyReduction_25 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut17 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn16
|
|
Packit |
2cbdf3 |
(happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_26 = happySpecReduce_3 13# happyReduction_26
|
|
Packit |
2cbdf3 |
happyReduction_26 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut18 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut17 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
happyIn17
|
|
Packit |
2cbdf3 |
((happy_var_1,0) : happy_var_3
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_27 = happySpecReduce_1 13# happyReduction_27
|
|
Packit |
2cbdf3 |
happyReduction_27 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut18 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn17
|
|
Packit |
2cbdf3 |
([(happy_var_1,0)]
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_28 = happySpecReduce_1 14# happyReduction_28
|
|
Packit |
2cbdf3 |
happyReduction_28 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn18
|
|
Packit |
2cbdf3 |
("0"
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_29 = happySpecReduce_1 14# happyReduction_29
|
|
Packit |
2cbdf3 |
happyReduction_29 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { (T _ (IdT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
happyIn18
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_30 = happySpecReduce_1 15# happyReduction_30
|
|
Packit |
2cbdf3 |
happyReduction_30 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn19
|
|
Packit |
2cbdf3 |
(case happy_var_1 of T _ (CodeT code) -> Just code
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_31 = happySpecReduce_1 15# happyReduction_31
|
|
Packit |
2cbdf3 |
happyReduction_31 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn19
|
|
Packit |
2cbdf3 |
(Nothing
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_32 = happySpecReduce_3 16# happyReduction_32
|
|
Packit |
2cbdf3 |
happyReduction_32 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut21 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut23 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
case happyOut22 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
happyIn20
|
|
Packit |
2cbdf3 |
((Just happy_var_1,happy_var_2,happy_var_3)
|
|
Packit |
2cbdf3 |
)}}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_33 = happySpecReduce_2 16# happyReduction_33
|
|
Packit |
2cbdf3 |
happyReduction_33 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut23 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut22 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn20
|
|
Packit |
2cbdf3 |
((Nothing,happy_var_1,happy_var_2)
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_34 = happySpecReduce_1 17# happyReduction_34
|
|
Packit |
2cbdf3 |
happyReduction_34 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn21
|
|
Packit |
2cbdf3 |
(charSetSingleton '\n'
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_35 = happySpecReduce_2 17# happyReduction_35
|
|
Packit |
2cbdf3 |
happyReduction_35 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut28 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn21
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_36 = happySpecReduce_1 18# happyReduction_36
|
|
Packit |
2cbdf3 |
happyReduction_36 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn22
|
|
Packit |
2cbdf3 |
(RightContextRExp (Ch (charSetSingleton '\n'))
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_37 = happySpecReduce_2 18# happyReduction_37
|
|
Packit |
2cbdf3 |
happyReduction_37 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut23 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn22
|
|
Packit |
2cbdf3 |
(RightContextRExp happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_38 = happySpecReduce_2 18# happyReduction_38
|
|
Packit |
2cbdf3 |
happyReduction_38 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn22
|
|
Packit |
2cbdf3 |
(RightContextCode (case happy_var_2 of
|
|
Packit |
2cbdf3 |
T _ (CodeT code) -> code)
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_39 = happySpecReduce_0 18# happyReduction_39
|
|
Packit |
2cbdf3 |
happyReduction_39 = happyIn22
|
|
Packit |
2cbdf3 |
(NoRightContext
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_40 = happySpecReduce_3 19# happyReduction_40
|
|
Packit |
2cbdf3 |
happyReduction_40 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut24 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut23 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
happyIn23
|
|
Packit |
2cbdf3 |
(happy_var_1 :| happy_var_3
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_41 = happySpecReduce_1 19# happyReduction_41
|
|
Packit |
2cbdf3 |
happyReduction_41 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut24 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn23
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_42 = happySpecReduce_2 20# happyReduction_42
|
|
Packit |
2cbdf3 |
happyReduction_42 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut24 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut25 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn24
|
|
Packit |
2cbdf3 |
(happy_var_1 :%% happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_43 = happySpecReduce_1 20# happyReduction_43
|
|
Packit |
2cbdf3 |
happyReduction_43 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut25 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn24
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_44 = happySpecReduce_2 21# happyReduction_44
|
|
Packit |
2cbdf3 |
happyReduction_44 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut27 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut26 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn25
|
|
Packit |
2cbdf3 |
(happy_var_2 happy_var_1
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_45 = happySpecReduce_1 21# happyReduction_45
|
|
Packit |
2cbdf3 |
happyReduction_45 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut27 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn25
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_46 = happySpecReduce_1 22# happyReduction_46
|
|
Packit |
2cbdf3 |
happyReduction_46 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn26
|
|
Packit |
2cbdf3 |
(Star
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_47 = happySpecReduce_1 22# happyReduction_47
|
|
Packit |
2cbdf3 |
happyReduction_47 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn26
|
|
Packit |
2cbdf3 |
(Plus
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_48 = happySpecReduce_1 22# happyReduction_48
|
|
Packit |
2cbdf3 |
happyReduction_48 happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn26
|
|
Packit |
2cbdf3 |
(Ques
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_49 = happySpecReduce_3 22# happyReduction_49
|
|
Packit |
2cbdf3 |
happyReduction_49 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (CharT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn26
|
|
Packit |
2cbdf3 |
(repeat_rng (digit happy_var_2) Nothing
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_50 = happyReduce 4# 22# happyReduction_50
|
|
Packit |
2cbdf3 |
happyReduction_50 (happy_x_4 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_3 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest)
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (CharT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
happyIn26
|
|
Packit |
2cbdf3 |
(repeat_rng (digit happy_var_2) (Just Nothing)
|
|
Packit |
2cbdf3 |
) `HappyStk` happyRest}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_51 = happyReduce 5# 22# happyReduction_51
|
|
Packit |
2cbdf3 |
happyReduction_51 (happy_x_5 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_4 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_3 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest)
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_2 of { (T _ (CharT happy_var_2)) ->
|
|
Packit |
2cbdf3 |
case happyOutTok happy_x_4 of { (T _ (CharT happy_var_4)) ->
|
|
Packit |
2cbdf3 |
happyIn26
|
|
Packit |
2cbdf3 |
(repeat_rng (digit happy_var_2) (Just (Just (digit happy_var_4)))
|
|
Packit |
2cbdf3 |
) `HappyStk` happyRest}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_52 = happySpecReduce_2 23# happyReduction_52
|
|
Packit |
2cbdf3 |
happyReduction_52 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= happyIn27
|
|
Packit |
2cbdf3 |
(Eps
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_53 = happySpecReduce_1 23# happyReduction_53
|
|
Packit |
2cbdf3 |
happyReduction_53 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { (T _ (StringT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
happyIn27
|
|
Packit |
2cbdf3 |
(foldr (:%%) Eps
|
|
Packit |
2cbdf3 |
(map (Ch . charSetSingleton) happy_var_1)
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_54 = happyMonadReduce 1# 23# happyReduction_54
|
|
Packit |
2cbdf3 |
happyReduction_54 (happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { (T _ (RMacT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
( lookupRMac happy_var_1)}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn27 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_55 = happySpecReduce_1 23# happyReduction_55
|
|
Packit |
2cbdf3 |
happyReduction_55 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut28 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn27
|
|
Packit |
2cbdf3 |
(Ch happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_56 = happySpecReduce_3 23# happyReduction_56
|
|
Packit |
2cbdf3 |
happyReduction_56 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut23 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn27
|
|
Packit |
2cbdf3 |
(happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_57 = happySpecReduce_3 24# happyReduction_57
|
|
Packit |
2cbdf3 |
happyReduction_57 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut28 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut29 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
happyIn28
|
|
Packit |
2cbdf3 |
(happy_var_1 `charSetMinus` happy_var_3
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_58 = happySpecReduce_1 24# happyReduction_58
|
|
Packit |
2cbdf3 |
happyReduction_58 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut29 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn28
|
|
Packit |
2cbdf3 |
(happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_59 = happySpecReduce_1 25# happyReduction_59
|
|
Packit |
2cbdf3 |
happyReduction_59 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { (T _ (CharT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
happyIn29
|
|
Packit |
2cbdf3 |
(charSetSingleton happy_var_1
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_60 = happySpecReduce_3 25# happyReduction_60
|
|
Packit |
2cbdf3 |
happyReduction_60 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { (T _ (CharT happy_var_1)) ->
|
|
Packit |
2cbdf3 |
case happyOutTok happy_x_3 of { (T _ (CharT happy_var_3)) ->
|
|
Packit |
2cbdf3 |
happyIn29
|
|
Packit |
2cbdf3 |
(charSetRange happy_var_1 happy_var_3
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_61 = happyMonadReduce 1# 25# happyReduction_61
|
|
Packit |
2cbdf3 |
happyReduction_61 (happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOut31 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
( lookupSMac happy_var_1)}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn29 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_62 = happySpecReduce_3 25# happyReduction_62
|
|
Packit |
2cbdf3 |
happyReduction_62 happy_x_3
|
|
Packit |
2cbdf3 |
happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut30 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn29
|
|
Packit |
2cbdf3 |
(foldr charSetUnion emptyCharSet happy_var_2
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_63 = happyMonadReduce 4# 25# happyReduction_63
|
|
Packit |
2cbdf3 |
happyReduction_63 (happy_x_4 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_3 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut30 happy_x_3 of { happy_var_3 ->
|
|
Packit |
2cbdf3 |
( do { dot <- lookupSMac (tokPosn happy_var_1, ".");
|
|
Packit |
2cbdf3 |
return (dot `charSetMinus`
|
|
Packit |
2cbdf3 |
foldr charSetUnion emptyCharSet happy_var_3) })}}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn29 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_64 = happyMonadReduce 2# 25# happyReduction_64
|
|
Packit |
2cbdf3 |
happyReduction_64 (happy_x_2 `HappyStk`
|
|
Packit |
2cbdf3 |
happy_x_1 `HappyStk`
|
|
Packit |
2cbdf3 |
happyRest) tk
|
|
Packit |
2cbdf3 |
= happyThen (case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut29 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
( do { dot <- lookupSMac (tokPosn happy_var_1, ".");
|
|
Packit |
2cbdf3 |
return (dot `charSetMinus` happy_var_2) })}}
|
|
Packit |
2cbdf3 |
) (\r -> happyReturn (happyIn29 r))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_65 = happySpecReduce_2 26# happyReduction_65
|
|
Packit |
2cbdf3 |
happyReduction_65 happy_x_2
|
|
Packit |
2cbdf3 |
happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOut28 happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
case happyOut30 happy_x_2 of { happy_var_2 ->
|
|
Packit |
2cbdf3 |
happyIn30
|
|
Packit |
2cbdf3 |
(happy_var_1 : happy_var_2
|
|
Packit |
2cbdf3 |
)}}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_66 = happySpecReduce_0 26# happyReduction_66
|
|
Packit |
2cbdf3 |
happyReduction_66 = happyIn30
|
|
Packit |
2cbdf3 |
([]
|
|
Packit |
2cbdf3 |
)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_67 = happySpecReduce_1 27# happyReduction_67
|
|
Packit |
2cbdf3 |
happyReduction_67 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn31
|
|
Packit |
2cbdf3 |
((tokPosn happy_var_1, ".")
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce_68 = happySpecReduce_1 27# happyReduction_68
|
|
Packit |
2cbdf3 |
happyReduction_68 happy_x_1
|
|
Packit |
2cbdf3 |
= case happyOutTok happy_x_1 of { happy_var_1 ->
|
|
Packit |
2cbdf3 |
happyIn31
|
|
Packit |
2cbdf3 |
(case happy_var_1 of T p (SMacT s) -> (p, s)
|
|
Packit |
2cbdf3 |
)}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyNewToken action sts stk
|
|
Packit |
2cbdf3 |
= lexer(\tk ->
|
|
Packit |
2cbdf3 |
let cont i = happyDoAction i tk action sts stk in
|
|
Packit |
2cbdf3 |
case tk of {
|
|
Packit |
2cbdf3 |
T _ EOFT -> happyDoAction 37# tk action sts stk;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '.') -> cont 1#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT ';') -> cont 2#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '<') -> cont 3#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '>') -> cont 4#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT ',') -> cont 5#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '$') -> cont 6#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '|') -> cont 7#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '*') -> cont 8#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '+') -> cont 9#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '?') -> cont 10#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '{') -> cont 11#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '}') -> cont 12#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '(') -> cont 13#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT ')') -> cont 14#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '#') -> cont 15#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '~') -> cont 16#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '-') -> cont 17#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '[') -> cont 18#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT ']') -> cont 19#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '^') -> cont 20#;
|
|
Packit |
2cbdf3 |
T _ (SpecialT '/') -> cont 21#;
|
|
Packit |
2cbdf3 |
T _ ZeroT -> cont 22#;
|
|
Packit |
2cbdf3 |
T _ (StringT happy_dollar_dollar) -> cont 23#;
|
|
Packit |
2cbdf3 |
T _ (BindT happy_dollar_dollar) -> cont 24#;
|
|
Packit |
2cbdf3 |
T _ (IdT happy_dollar_dollar) -> cont 25#;
|
|
Packit |
2cbdf3 |
T _ (CodeT _) -> cont 26#;
|
|
Packit |
2cbdf3 |
T _ (CharT happy_dollar_dollar) -> cont 27#;
|
|
Packit |
2cbdf3 |
T _ (SMacT _) -> cont 28#;
|
|
Packit |
2cbdf3 |
T _ (RMacT happy_dollar_dollar) -> cont 29#;
|
|
Packit |
2cbdf3 |
T _ (SMacDefT happy_dollar_dollar) -> cont 30#;
|
|
Packit |
2cbdf3 |
T _ (RMacDefT happy_dollar_dollar) -> cont 31#;
|
|
Packit |
2cbdf3 |
T _ WrapperT -> cont 32#;
|
|
Packit |
2cbdf3 |
T _ EncodingT -> cont 33#;
|
|
Packit |
2cbdf3 |
T _ ActionTypeT -> cont 34#;
|
|
Packit |
2cbdf3 |
T _ TokenTypeT -> cont 35#;
|
|
Packit |
2cbdf3 |
T _ TypeClassT -> cont 36#;
|
|
Packit |
2cbdf3 |
_ -> happyError' tk
|
|
Packit |
2cbdf3 |
})
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyError_ 37# tk = happyError' tk
|
|
Packit |
2cbdf3 |
happyError_ _ tk = happyError' tk
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyThen :: () => P a -> (a -> P b) -> P b
|
|
Packit |
2cbdf3 |
happyThen = ((>>=))
|
|
Packit |
2cbdf3 |
happyReturn :: () => a -> P a
|
|
Packit |
2cbdf3 |
happyReturn = (return)
|
|
Packit |
2cbdf3 |
happyThen1 = happyThen
|
|
Packit |
2cbdf3 |
happyReturn1 :: () => a -> P a
|
|
Packit |
2cbdf3 |
happyReturn1 = happyReturn
|
|
Packit |
2cbdf3 |
happyError' :: () => (Token) -> P a
|
|
Packit |
2cbdf3 |
happyError' tk = (\token -> happyError) tk
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
parse = happySomeParser where
|
|
Packit |
2cbdf3 |
happySomeParser = happyThen (happyParse 0#) (\x -> happyReturn (happyOut4 x))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happySeq = happyDontSeq
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyError :: P a
|
|
Packit |
2cbdf3 |
happyError = failP "parse error"
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- -----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Utils
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
digit c = ord c - ord '0'
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
repeat_rng :: Int -> Maybe (Maybe Int) -> (RExp->RExp)
|
|
Packit |
2cbdf3 |
repeat_rng n (Nothing) re = foldr (:%%) Eps (replicate n re)
|
|
Packit |
2cbdf3 |
repeat_rng n (Just Nothing) re = foldr (:%%) (Star re) (replicate n re)
|
|
Packit |
2cbdf3 |
repeat_rng n (Just (Just m)) re = intl :%% rst
|
|
Packit |
2cbdf3 |
where
|
|
Packit |
2cbdf3 |
intl = repeat_rng n Nothing re
|
|
Packit |
2cbdf3 |
rst = foldr (\re re'->Ques(re :%% re')) Eps (replicate (m-n) re)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
replaceCodes codes rectx = rectx{ reCtxStartCodes = codes }
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
lookupEncoding :: String -> P Encoding
|
|
Packit |
2cbdf3 |
lookupEncoding s = case map toLower s of
|
|
Packit |
2cbdf3 |
"iso-8859-1" -> return Latin1
|
|
Packit |
2cbdf3 |
"latin1" -> return Latin1
|
|
Packit |
2cbdf3 |
"utf-8" -> return UTF8
|
|
Packit |
2cbdf3 |
"utf8" -> return UTF8
|
|
Packit |
2cbdf3 |
_ -> failP ("encoding " ++ show s ++ " not supported")
|
|
Packit |
2cbdf3 |
{-# LINE 1 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
{-# LINE 1 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
{-# LINE 1 "<built-in>" #-}
|
|
Packit |
2cbdf3 |
{-# LINE 1 "<command-line>" #-}
|
|
Packit |
2cbdf3 |
{-# LINE 1 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
-- Id: GenericTemplate.hs,v 1.26 2005/01/14 14:47:22 simonmar Exp
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# LINE 13 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- Do not remove this comment. Required to fix CPP parsing when using GCC and a clang-compiled alex.
|
|
Packit |
2cbdf3 |
#if __GLASGOW_HASKELL__ > 706
|
|
Packit |
2cbdf3 |
#define LT(n,m) ((Happy_GHC_Exts.tagToEnum# (n Happy_GHC_Exts.<# m)) :: Bool)
|
|
Packit |
2cbdf3 |
#define GTE(n,m) ((Happy_GHC_Exts.tagToEnum# (n Happy_GHC_Exts.>=# m)) :: Bool)
|
|
Packit |
2cbdf3 |
#define EQ(n,m) ((Happy_GHC_Exts.tagToEnum# (n Happy_GHC_Exts.==# m)) :: Bool)
|
|
Packit |
2cbdf3 |
#else
|
|
Packit |
2cbdf3 |
#define LT(n,m) (n Happy_GHC_Exts.<# m)
|
|
Packit |
2cbdf3 |
#define GTE(n,m) (n Happy_GHC_Exts.>=# m)
|
|
Packit |
2cbdf3 |
#define EQ(n,m) (n Happy_GHC_Exts.==# m)
|
|
Packit |
2cbdf3 |
#endif
|
|
Packit |
2cbdf3 |
{-# LINE 46 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
data Happy_IntList = HappyCons Happy_GHC_Exts.Int# Happy_IntList
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# LINE 67 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# LINE 77 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# LINE 86 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
infixr 9 `HappyStk`
|
|
Packit |
2cbdf3 |
data HappyStk a = HappyStk a (HappyStk a)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- starting the parse
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyParse start_state = happyNewToken start_state notHappyAtAll notHappyAtAll
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Accepting the parse
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- If the current token is 0#, it means we've just accepted a partial
|
|
Packit |
2cbdf3 |
-- parse (a %partial parser). We must ignore the saved token on the top of
|
|
Packit |
2cbdf3 |
-- the stack in this case.
|
|
Packit |
2cbdf3 |
happyAccept 0# tk st sts (_ `HappyStk` ans `HappyStk` _) =
|
|
Packit |
2cbdf3 |
happyReturn1 ans
|
|
Packit |
2cbdf3 |
happyAccept j tk st sts (HappyStk ans _) =
|
|
Packit |
2cbdf3 |
(happyTcHack j (happyTcHack st)) (happyReturn1 ans)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Arrays only: do the next action
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyDoAction i tk st
|
|
Packit |
2cbdf3 |
= {- nothing -}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
case action of
|
|
Packit |
2cbdf3 |
0# -> {- nothing -}
|
|
Packit |
2cbdf3 |
happyFail i tk st
|
|
Packit |
2cbdf3 |
-1# -> {- nothing -}
|
|
Packit |
2cbdf3 |
happyAccept i tk st
|
|
Packit |
2cbdf3 |
n | LT(n,(0# :: Happy_GHC_Exts.Int#)) -> {- nothing -}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
(happyReduceArr Happy_Data_Array.! rule) i tk st
|
|
Packit |
2cbdf3 |
where rule = (Happy_GHC_Exts.I# ((Happy_GHC_Exts.negateInt# ((n Happy_GHC_Exts.+# (1# :: Happy_GHC_Exts.Int#))))))
|
|
Packit |
2cbdf3 |
n -> {- nothing -}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyShift new_state i tk st
|
|
Packit |
2cbdf3 |
where new_state = (n Happy_GHC_Exts.-# (1# :: Happy_GHC_Exts.Int#))
|
|
Packit |
2cbdf3 |
where off = indexShortOffAddr happyActOffsets st
|
|
Packit |
2cbdf3 |
off_i = (off Happy_GHC_Exts.+# i)
|
|
Packit |
2cbdf3 |
check = if GTE(off_i,(0# :: Happy_GHC_Exts.Int#))
|
|
Packit |
2cbdf3 |
then EQ(indexShortOffAddr happyCheck off_i, i)
|
|
Packit |
2cbdf3 |
else False
|
|
Packit |
2cbdf3 |
action
|
|
Packit |
2cbdf3 |
| check = indexShortOffAddr happyTable off_i
|
|
Packit |
2cbdf3 |
| otherwise = indexShortOffAddr happyDefActions st
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
indexShortOffAddr (HappyA# arr) off =
|
|
Packit |
2cbdf3 |
Happy_GHC_Exts.narrow16Int# i
|
|
Packit |
2cbdf3 |
where
|
|
Packit |
2cbdf3 |
i = Happy_GHC_Exts.word2Int# (Happy_GHC_Exts.or# (Happy_GHC_Exts.uncheckedShiftL# high 8#) low)
|
|
Packit |
2cbdf3 |
high = Happy_GHC_Exts.int2Word# (Happy_GHC_Exts.ord# (Happy_GHC_Exts.indexCharOffAddr# arr (off' Happy_GHC_Exts.+# 1#)))
|
|
Packit |
2cbdf3 |
low = Happy_GHC_Exts.int2Word# (Happy_GHC_Exts.ord# (Happy_GHC_Exts.indexCharOffAddr# arr off'))
|
|
Packit |
2cbdf3 |
off' = off Happy_GHC_Exts.*# 2#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
data HappyAddr = HappyA# Happy_GHC_Exts.Addr#
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- HappyState data type (not arrays)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# LINE 170 "templates/GenericTemplate.hs" #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Shifting a token
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyShift new_state 0# tk st sts stk@(x `HappyStk` _) =
|
|
Packit |
2cbdf3 |
let i = (case Happy_GHC_Exts.unsafeCoerce# x of { (Happy_GHC_Exts.I# (i)) -> i }) in
|
|
Packit |
2cbdf3 |
-- trace "shifting the error token" $
|
|
Packit |
2cbdf3 |
happyDoAction i tk new_state (HappyCons (st) (sts)) (stk)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyShift new_state i tk st sts stk =
|
|
Packit |
2cbdf3 |
happyNewToken new_state (HappyCons (st) (sts)) ((happyInTok (tk))`HappyStk`stk)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- happyReduce is specialised for the common cases.
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happySpecReduce_0 i fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happySpecReduce_0 nt fn j tk st@((action)) sts stk
|
|
Packit |
2cbdf3 |
= happyGoto nt j tk st (HappyCons (st) (sts)) (fn `HappyStk` stk)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happySpecReduce_1 i fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happySpecReduce_1 nt fn j tk _ sts@((HappyCons (st@(action)) (_))) (v1`HappyStk`stk')
|
|
Packit |
2cbdf3 |
= let r = fn v1 in
|
|
Packit |
2cbdf3 |
happySeq r (happyGoto nt j tk st sts (r `HappyStk` stk'))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happySpecReduce_2 i fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happySpecReduce_2 nt fn j tk _ (HappyCons (_) (sts@((HappyCons (st@(action)) (_))))) (v1`HappyStk`v2`HappyStk`stk')
|
|
Packit |
2cbdf3 |
= let r = fn v1 v2 in
|
|
Packit |
2cbdf3 |
happySeq r (happyGoto nt j tk st sts (r `HappyStk` stk'))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happySpecReduce_3 i fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happySpecReduce_3 nt fn j tk _ (HappyCons (_) ((HappyCons (_) (sts@((HappyCons (st@(action)) (_))))))) (v1`HappyStk`v2`HappyStk`v3`HappyStk`stk')
|
|
Packit |
2cbdf3 |
= let r = fn v1 v2 v3 in
|
|
Packit |
2cbdf3 |
happySeq r (happyGoto nt j tk st sts (r `HappyStk` stk'))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyReduce k i fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happyReduce k nt fn j tk st sts stk
|
|
Packit |
2cbdf3 |
= case happyDrop (k Happy_GHC_Exts.-# (1# :: Happy_GHC_Exts.Int#)) sts of
|
|
Packit |
2cbdf3 |
sts1@((HappyCons (st1@(action)) (_))) ->
|
|
Packit |
2cbdf3 |
let r = fn stk in -- it doesn't hurt to always seq here...
|
|
Packit |
2cbdf3 |
happyDoSeq r (happyGoto nt j tk st1 sts1 r)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyMonadReduce k nt fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happyMonadReduce k nt fn j tk st sts stk =
|
|
Packit |
2cbdf3 |
case happyDrop k (HappyCons (st) (sts)) of
|
|
Packit |
2cbdf3 |
sts1@((HappyCons (st1@(action)) (_))) ->
|
|
Packit |
2cbdf3 |
let drop_stk = happyDropStk k stk in
|
|
Packit |
2cbdf3 |
happyThen1 (fn stk tk) (\r -> happyGoto nt j tk st1 sts1 (r `HappyStk` drop_stk))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyMonad2Reduce k nt fn 0# tk st sts stk
|
|
Packit |
2cbdf3 |
= happyFail 0# tk st sts stk
|
|
Packit |
2cbdf3 |
happyMonad2Reduce k nt fn j tk st sts stk =
|
|
Packit |
2cbdf3 |
case happyDrop k (HappyCons (st) (sts)) of
|
|
Packit |
2cbdf3 |
sts1@((HappyCons (st1@(action)) (_))) ->
|
|
Packit |
2cbdf3 |
let drop_stk = happyDropStk k stk
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
off = indexShortOffAddr happyGotoOffsets st1
|
|
Packit |
2cbdf3 |
off_i = (off Happy_GHC_Exts.+# nt)
|
|
Packit |
2cbdf3 |
new_state = indexShortOffAddr happyTable off_i
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
in
|
|
Packit |
2cbdf3 |
happyThen1 (fn stk tk) (\r -> happyNewToken new_state sts1 (r `HappyStk` drop_stk))
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyDrop 0# l = l
|
|
Packit |
2cbdf3 |
happyDrop n (HappyCons (_) (t)) = happyDrop (n Happy_GHC_Exts.-# (1# :: Happy_GHC_Exts.Int#)) t
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyDropStk 0# l = l
|
|
Packit |
2cbdf3 |
happyDropStk n (x `HappyStk` xs) = happyDropStk (n Happy_GHC_Exts.-# (1#::Happy_GHC_Exts.Int#)) xs
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Moving to a new state after a reduction
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyGoto nt j tk st =
|
|
Packit |
2cbdf3 |
{- nothing -}
|
|
Packit |
2cbdf3 |
happyDoAction j tk new_state
|
|
Packit |
2cbdf3 |
where off = indexShortOffAddr happyGotoOffsets st
|
|
Packit |
2cbdf3 |
off_i = (off Happy_GHC_Exts.+# nt)
|
|
Packit |
2cbdf3 |
new_state = indexShortOffAddr happyTable off_i
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Error recovery (0# is the error token)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- parse error if we are in recovery and we fail again
|
|
Packit |
2cbdf3 |
happyFail 0# tk old_st _ stk@(x `HappyStk` _) =
|
|
Packit |
2cbdf3 |
let i = (case Happy_GHC_Exts.unsafeCoerce# x of { (Happy_GHC_Exts.I# (i)) -> i }) in
|
|
Packit |
2cbdf3 |
-- trace "failing" $
|
|
Packit |
2cbdf3 |
happyError_ i tk
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{- We don't need state discarding for our restricted implementation of
|
|
Packit |
2cbdf3 |
"error". In fact, it can cause some bogus parses, so I've disabled it
|
|
Packit |
2cbdf3 |
for now --SDM
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- discard a state
|
|
Packit |
2cbdf3 |
happyFail 0# tk old_st (HappyCons ((action)) (sts))
|
|
Packit |
2cbdf3 |
(saved_tok `HappyStk` _ `HappyStk` stk) =
|
|
Packit |
2cbdf3 |
-- trace ("discarding state, depth " ++ show (length stk)) $
|
|
Packit |
2cbdf3 |
happyDoAction 0# tk action sts ((saved_tok`HappyStk`stk))
|
|
Packit |
2cbdf3 |
-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- Enter error recovery: generate an error token,
|
|
Packit |
2cbdf3 |
-- save the old token and carry on.
|
|
Packit |
2cbdf3 |
happyFail i tk (action) sts stk =
|
|
Packit |
2cbdf3 |
-- trace "entering error recovery" $
|
|
Packit |
2cbdf3 |
happyDoAction 0# tk action sts ( (Happy_GHC_Exts.unsafeCoerce# (Happy_GHC_Exts.I# (i))) `HappyStk` stk)
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- Internal happy errors:
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
notHappyAtAll :: a
|
|
Packit |
2cbdf3 |
notHappyAtAll = error "Internal Happy error\n"
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Hack to get the typechecker to accept our action functions
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyTcHack :: Happy_GHC_Exts.Int# -> a -> a
|
|
Packit |
2cbdf3 |
happyTcHack x y = y
|
|
Packit |
2cbdf3 |
{-# INLINE happyTcHack #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Seq-ing. If the --strict flag is given, then Happy emits
|
|
Packit |
2cbdf3 |
-- happySeq = happyDoSeq
|
|
Packit |
2cbdf3 |
-- otherwise it emits
|
|
Packit |
2cbdf3 |
-- happySeq = happyDontSeq
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
happyDoSeq, happyDontSeq :: a -> b -> b
|
|
Packit |
2cbdf3 |
happyDoSeq a b = a `seq` b
|
|
Packit |
2cbdf3 |
happyDontSeq a b = b
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-----------------------------------------------------------------------------
|
|
Packit |
2cbdf3 |
-- Don't inline any functions from the template. GHC has a nasty habit
|
|
Packit |
2cbdf3 |
-- of deciding to inline happyGoto everywhere, which increases the size of
|
|
Packit |
2cbdf3 |
-- the generated parser quite a bit.
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyDoAction #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyTable #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyCheck #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyActOffsets #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyGotoOffsets #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyDefActions #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyShift #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happySpecReduce_0 #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happySpecReduce_1 #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happySpecReduce_2 #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happySpecReduce_3 #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyReduce #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyMonadReduce #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyGoto #-}
|
|
Packit |
2cbdf3 |
{-# NOINLINE happyFail #-}
|
|
Packit |
2cbdf3 |
|
|
Packit |
2cbdf3 |
-- end of Happy Template.
|