a more compact showtree
This commit is contained in:
parent
9b5a35b5d2
commit
d172cd0d6e
@ -121,7 +121,7 @@ treeany f t = (f $ root t) || (any (treeany f) $ branches t)
|
|||||||
-- treedropall -- do this repeatedly.
|
-- treedropall -- do this repeatedly.
|
||||||
|
|
||||||
showtree :: Show a => Tree a -> String
|
showtree :: Show a => Tree a -> String
|
||||||
showtree = drawTree . treemap show
|
showtree = unlines . filter (containsRegex (mkRegex "[^ |]")) . lines . drawTree . treemap show
|
||||||
|
|
||||||
-- debugging
|
-- debugging
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user