summaryrefslogtreecommitdiff
path: root/dht/Presence/Nesting.hs
diff options
context:
space:
mode:
Diffstat (limited to 'dht/Presence/Nesting.hs')
-rw-r--r--dht/Presence/Nesting.hs7
1 files changed, 7 insertions, 0 deletions
diff --git a/dht/Presence/Nesting.hs b/dht/Presence/Nesting.hs
index cf47c9fc..403d63cf 100644
--- a/dht/Presence/Nesting.hs
+++ b/dht/Presence/Nesting.hs
@@ -24,6 +24,13 @@ doNestingXML :: Monad m => NestingXML o m r -> ConduitM Event o m r
24doNestingXML m = 24doNestingXML m =
25 evalStateC (XMLState 0 StrictNil) (trackNesting .| m) 25 evalStateC (XMLState 0 StrictNil) (trackNesting .| m)
26 26
27startNestingXML :: Monad m => NestingXML o m r -> ConduitM Event o m (r, XMLState)
28startNestingXML m =
29 runStateC (XMLState 0 StrictNil) (trackNesting .| m)
30
31finishNestingXML :: Monad m => XMLState -> NestingXML o m r -> ConduitM Event o m r
32finishNestingXML = evalStateC
33
27nesting :: Monad m => NestingXML o m Int 34nesting :: Monad m => NestingXML o m Int
28nesting = lift $ (return . nestingLevel) =<< get 35nesting = lift $ (return . nestingLevel) =<< get
29 36