fixed loop in anti loop detection
This commit is contained in:
parent
47411226ac
commit
7fcd27aafd
|
@ -85,7 +85,7 @@ detectLoop v g i =
|
|||
else case M.lookup i g of
|
||||
Nothing -> pure v -- this has already been removed, meaning this branch is safe
|
||||
Just is -> if is == S.empty
|
||||
then pure v -- leaf \/ Set not Traversable
|
||||
then pure (S.insert i v)
|
||||
else S.unions <$> detectLoop (S.insert i v) g <~> S.toList is
|
||||
|
||||
createGraph :: [TL] -> RefGraph
|
||||
|
|
Loading…
Reference in New Issue
Block a user