diff options
author | Albert Krewinkel <albert@zeitkraut.de> | 2016-05-12 23:11:26 +0200 |
---|---|---|
committer | Albert Krewinkel <albert@zeitkraut.de> | 2016-05-19 09:33:51 +0200 |
commit | 1dda5353781fa605c00dd18af5f8527bc31956ef (patch) | |
tree | 9af10ef6fcf44a1d16c6a014662bc0502557d5cc /src/Text/Pandoc/Readers/Org | |
parent | dd649f19a905dee87fd27adbfdf3ac3ca250238c (diff) | |
download | pandoc-1dda5353781fa605c00dd18af5f8527bc31956ef.tar.gz |
Org reader: refactor block attribute handling
A parser state attribute was used to keep track of block attributes
defined in meta-lines. Global state is undesirable, so block attributes
are no longer saved as part of the parser state. Old functions and the
respective part of the parser state are removed.
Diffstat (limited to 'src/Text/Pandoc/Readers/Org')
-rw-r--r-- | src/Text/Pandoc/Readers/Org/ParserState.hs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/src/Text/Pandoc/Readers/Org/ParserState.hs b/src/Text/Pandoc/Readers/Org/ParserState.hs index 49cfa2be2..f84e5e51b 100644 --- a/src/Text/Pandoc/Readers/Org/ParserState.hs +++ b/src/Text/Pandoc/Readers/Org/ParserState.hs @@ -68,8 +68,6 @@ import Text.Pandoc.Parsing ( HasHeaderMap(..) type OrgNoteRecord = (String, F Blocks) -- | Table of footnotes type OrgNoteTable = [OrgNoteRecord] --- | Map of org block attributes (e.g. LABEL, CAPTION, NAME, etc) -type OrgBlockAttributes = M.Map String String -- | Map of functions for link transformations. The map key is refers to the -- link-type, the corresponding function transforms the given link string. type OrgLinkFormatters = M.Map String (String -> String) @@ -84,7 +82,6 @@ data ExportSettings = ExportSettings data OrgParserState = OrgParserState { orgStateOptions :: ReaderOptions , orgStateAnchorIds :: [String] - , orgStateBlockAttributes :: OrgBlockAttributes , orgStateEmphasisCharStack :: [Char] , orgStateEmphasisNewlines :: Maybe Int , orgStateExportSettings :: ExportSettings @@ -140,7 +137,6 @@ defaultOrgParserState :: OrgParserState defaultOrgParserState = OrgParserState { orgStateOptions = def , orgStateAnchorIds = [] - , orgStateBlockAttributes = M.empty , orgStateEmphasisCharStack = [] , orgStateEmphasisNewlines = Nothing , orgStateExportSettings = def |