1
1
mirror of https://github.com/github/semantic.git synced 2025-01-01 19:55:34 +03:00

No IO needed

This commit is contained in:
Matt Diephouse 2016-01-28 16:14:24 -05:00
parent cf1440a81c
commit d76fbfa60e
2 changed files with 3 additions and 3 deletions

View File

@ -65,7 +65,7 @@ printDiff arguments diff sources = case format arguments of
put chunks = do
renderer <- byteStringMakerFromEnvironment
B1.putStr $ mconcat $ chunksToByteStrings renderer chunks
Split -> put (output arguments) =<< split diff sources
Split -> put (output arguments) $ split diff sources
where
put Nothing rendered = TextIO.putStr rendered
put (Just path) rendered = do

View File

@ -31,8 +31,8 @@ type ClassName = T.Text
classifyMarkup :: Foldable f => f String -> Markup -> Markup
classifyMarkup categories element = maybe element ((element !) . A.class_ . stringValue . ("category-" ++)) $ maybeFirst categories
split :: Renderer leaf (IO TL.Text)
split diff (before, after) = return . renderHtml
split :: Renderer leaf TL.Text
split diff (before, after) = renderHtml
. docTypeHtml
. ((head $ link ! A.rel "stylesheet" ! A.href "style.css") <>)
. body