--Epsilonルール１ステップで移動可能な状態の集合を得る
eclose' :: (Eq a) => D.State a -> [Rule a b] -> [D.State a]
eclose' s rs = enext
  where
    erule = L.filter (\(Rule x y _) -> case y of
                                         (Right _) -> (x == s)
                                         (Left _) -> False) rs
    enext = L.map (\(Rule _ _ ns) -> ns) erule

--Epsilonルールで移動可能な状態の集合を得る
eclose'' :: (Eq a) => [D.State a] -> [Rule a b] -> [D.State a] -> [D.State a]
eclose' :: (Eq a) => D.State a -> [Rule a b] -> [D.State a]
eclose' s rs = enext
  where
    erule = L.filter (\(Rule x y _) -> case y of
                                         (Right _) -> (x == s)
                                         (Left _) -> False) rs
    enext = L.map (\(Rule _ _ ns) -> ns) erule

--Epsilonルールで移動可能な状態の集合を得る
eclose' s rs = enext
  where
    erule = L.filter (\(Rule x y _) -> case y of
                                         (Right _) -> (x == s)
                                         (Left _) -> False) rs
    enext = L.map (\(Rule _ _ ns) -> ns) erule

--Epsilonルールで移動可能な状態の集合を得る