ghc-tags-core-0.2.1.0: a library to work with tags created from Haskell parsed tree

Safe HaskellNone
LanguageHaskell2010

GhcTags.Stream

Description

Parse and combine a stream of tags.

Synopsis

Documentation

tagParser Source #

Arguments

:: MonadIO m 
=> Parser (Maybe (Tag tk))

Parse a single tag. For Vim this returns should parse a single line and return the tag, e.g parseTagLine.

-> Producer ByteString m () 
-> Producer (Tag tk) m () 

Parse a stream of tags, coming from a Text producer.

combineTagsPipe Source #

Arguments

:: forall (tk :: TAG_KIND). Applicative m 
=> (Tag tk -> Tag tk -> Ordering) 
-> RawFilePath

file path from which the new tags were obtained, it should be normalised

-> Tag tk

tag read from disc

-> [Tag tk]

new tags

-> Producer (Tag tk) m [Tag tk] 

Streaming version of combineTags.

runCombineTagsPipe :: MonadIO m => Handle -> (Tag tk -> Tag tk -> Ordering) -> (Tag tk -> Builder) -> RawFilePath -> Tag tk -> Effect (StateT [Tag tk] m) () Source #

run combineTagsPipe taking care of the state.