diff options
author | Joey Hess <joey@kitenet.net> | 2012-12-13 00:24:19 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-12-13 00:24:19 -0400 |
commit | 94554782894ec6c26da3b46312d5d1d16d596458 (patch) | |
tree | 78746106bfb153945ccbfd2bbae536081c005e91 /Utility/Tense.hs | |
parent | 55bd61d8c42aaf36a3c57f8444c493f6b045f4cd (diff) |
finished where indentation changes
Diffstat (limited to 'Utility/Tense.hs')
-rw-r--r-- | Utility/Tense.hs | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/Utility/Tense.hs b/Utility/Tense.hs index 135a90af2..60b3fa513 100644 --- a/Utility/Tense.hs +++ b/Utility/Tense.hs @@ -32,11 +32,11 @@ instance IsString TenseText where renderTense :: Tense -> TenseText -> Text renderTense tense (TenseText chunks) = T.concat $ map render chunks - where - render (Tensed present past) - | tense == Present = present - | otherwise = past - render (UnTensed s) = s + where + render (Tensed present past) + | tense == Present = present + | otherwise = past + render (UnTensed s) = s {- Builds up a TenseText, separating chunks with spaces. - @@ -45,13 +45,13 @@ renderTense tense (TenseText chunks) = T.concat $ map render chunks -} tenseWords :: [TenseChunk] -> TenseText tenseWords = TenseText . go [] - where - go c [] = reverse c - go c (w:[]) = reverse (w:c) - go c ((UnTensed w):ws) = go (UnTensed (addspace w) : c) ws - go c ((Tensed w1 w2):ws) = - go (Tensed (addspace w1) (addspace w2) : c) ws - addspace w = T.append w " " + where + go c [] = reverse c + go c (w:[]) = reverse (w:c) + go c ((UnTensed w):ws) = go (UnTensed (addspace w) : c) ws + go c ((Tensed w1 w2):ws) = + go (Tensed (addspace w1) (addspace w2) : c) ws + addspace w = T.append w " " unTensed :: Text -> TenseText unTensed t = TenseText [UnTensed t] |