More perspicuous definition of nonindentSpaces.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@981 788f1e2b-df1e-0410-8736-df70ead52e1b
This commit is contained in:
parent
5c1632be5d
commit
f8f9fa49d6
1 changed files with 4 additions and 1 deletions
|
@ -74,7 +74,10 @@ indentSpaces = try $ do
|
|||
nonindentSpaces = do
|
||||
state <- getState
|
||||
let tabStop = stateTabStop state
|
||||
choice $ map (\n -> (try (count n (char ' ')))) $ reverse [0..(tabStop - 1)]
|
||||
sps <- many (char ' ')
|
||||
if length sps < tabStop
|
||||
then return sps
|
||||
else unexpected "indented line"
|
||||
|
||||
-- | Fail unless we're at beginning of a line.
|
||||
failUnlessBeginningOfLine = do
|
||||
|
|
Loading…
Add table
Reference in a new issue