fungll-combinators-0.1.0.1: GLL parser with simple combinator interface

Safe HaskellSafe
LanguageHaskell2010

GLL.Types.BSR

Synopsis

Documentation

type Input t = Array Int t Source #

type SlotL t = (Slot t, Int) Source #

type PrL t = (Prod t, Int) Source #

type NtL = (Nt, Int) Source #

type BSRs t = IntMap (IntMap (IntMap (Map (Prod t) IntSet))) Source #

Stores packed nodes using nested Data.IntMaps, nesting is as follows:

  • left extent
  • right extent
  • dot position (from left to right)
  • mapping from productions to set of pivots

type BSR t = (Slot t, Int, Int, Int) Source #

pNodeLookup :: Ord t => BSRs t -> (Slot t, Int, Int) -> Maybe [Int] Source #

pNodeLookup' :: Ord t => BSRs t -> ((Prod t, Int), Int, Int) -> Maybe [Int] Source #

addBSR :: Ord t => BSR t -> BSRs t -> BSRs t Source #

pMapInsert :: Ord t => BSR t -> BSRs t -> BSRs t Source #

showBSRs :: (Show a1, Show a2) => IntMap (IntMap (IntMap (Map a1 a2))) -> String Source #

mkInput :: Parseable t => [t] -> Input t Source #