1
0
forked from GitHub/gf-core

Some experiments with PSeq (left commented out)

This commit is contained in:
hallgren
2011-10-20 14:25:31 +00:00
parent ef4fac9d82
commit e5accc0d8d
2 changed files with 32 additions and 5 deletions

View File

@@ -574,3 +574,14 @@ topoSortJments (m,mi) = do
(\cyc -> Bad (render (text "circular definitions:" <+> fsep (map ppIdent (head cyc)))))
(topoTest (allDependencies (==m) (jments mi)))
return (reverse [(i,info) | i <- is, Ok info <- [lookupTree showIdent i (jments mi)]])
{-
-- | Smart constructor for PSeq
pSeq p1 p2 =
case (p1,p2) of
(PString s1,PString s2) -> PString (s1++s2)
(PSeq p11 (PString s1),PString s2) -> PSeq p11 (PString (s1++s2))
(PString s1,PSeq (PString s2) p22) -> PSeq (PString (s1++s2)) p22
(PSeq p11 (PString s1),PSeq (PString s2) p22) ->
PSeq p11 (PSeq (PString (s1++s2)) p22)
_ -> PSeq p1 p2
-}