Simplified freeNamesIn by removing what is an unnecessary case for replicators

This commit is contained in:
Neil Brown 2008-06-04 19:05:31 +00:00
parent cfbdfc555e
commit e2dac3aa76

View File

@ -73,9 +73,6 @@ freeNamesIn = doGeneric
doSpecType :: A.SpecType -> NameMap
doSpecType (A.Proc _ _ fs p) = Map.difference (freeNamesIn p) (freeNamesIn fs)
doSpecType (A.Function _ _ _ fs vp) = Map.difference (freeNamesIn vp) (freeNamesIn fs)
doSpecType (A.Rep _ rep) = case rep of
A.For _ b c -> Map.union (freeNamesIn b) (freeNamesIn c)
A.ForEach _ b -> freeNamesIn b
doSpecType st = doGeneric st
-- | Replace names.