diff options
author | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2007-04-15 16:20:07 +0000 |
---|---|---|
committer | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2007-04-15 16:20:07 +0000 |
commit | e15fd3bf86f91d6c14bf9ba2e2aa7057dc51d72b (patch) | |
tree | 08cd363c8fbb83cb85bd79d67d93866b2916fcfe /src/Text/ParserCombinators | |
parent | 24ee5f1f49ebb7e0cf54640a21518af084b7d06d (diff) | |
download | pandoc-e15fd3bf86f91d6c14bf9ba2e2aa7057dc51d72b.tar.gz |
Moved escape and nullBlock parsers from ParserCombinators/Pandoc
to Pandoc/Shared. Reason: ParserCombinators/Pandoc is for
general-purpose parsers that don't require Pandoc.Definition.
Also removed some unnecessary imports from Pandoc/Shared.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@584 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src/Text/ParserCombinators')
-rw-r--r-- | src/Text/ParserCombinators/Pandoc.hs | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/src/Text/ParserCombinators/Pandoc.hs b/src/Text/ParserCombinators/Pandoc.hs index a965159ed..f418e0e75 100644 --- a/src/Text/ParserCombinators/Pandoc.hs +++ b/src/Text/ParserCombinators/Pandoc.hs @@ -44,7 +44,6 @@ module Text.ParserCombinators.Pandoc ( lineClump ) where import Text.ParserCombinators.Parsec -import Text.Pandoc.Definition import Text.Pandoc.Shared import Data.Char ( toUpper, toLower ) @@ -52,13 +51,6 @@ import Data.Char ( toUpper, toLower ) anyLine :: GenParser Char st [Char] anyLine = manyTill anyChar (newline <|> (do{eof; return '\n'})) --- | Parses a character and returns 'Null' (so that the parser can move on --- if it gets stuck). -nullBlock :: GenParser Char st Block -nullBlock = do - anyChar - return Null - -- | Parses a space or tab. spaceChar :: CharParser st Char spaceChar = oneOf " \t" @@ -77,14 +69,6 @@ blankline = try (do blanklines :: GenParser Char st [Char] blanklines = try (many1 blankline) --- | Parses backslash, then applies character parser. -escaped :: GenParser Char st Char -- ^ Parser for character to escape - -> GenParser Char st Inline -escaped parser = try (do - char '\\' - result <- parser - return (Str [result])) - -- | Parses material enclosed between start and end parsers. enclosed :: GenParser Char st t -- ^ start parser -> GenParser Char st end -- ^ end parser |