From d55346ca9a8fcf773d40d1e1d938d71131aec645 Mon Sep 17 00:00:00 2001 From: fiddlosopher Date: Mon, 12 Mar 2007 00:23:39 +0000 Subject: Simplified keyTable, using assumption that key blocks are not inside other block elements (an assumption that the Markdown reader uses in making its initial pass anyway). git-svn-id: https://pandoc.googlecode.com/svn/trunk@574 788f1e2b-df1e-0410-8736-df70ead52e1b --- src/Text/Pandoc/Shared.hs | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'src/Text') diff --git a/src/Text/Pandoc/Shared.hs b/src/Text/Pandoc/Shared.hs index 6ecb31757..e5d6e77df 100644 --- a/src/Text/Pandoc/Shared.hs +++ b/src/Text/Pandoc/Shared.hs @@ -433,26 +433,6 @@ keyTable ((Key ref target):lst) = (((ref, target):table), rest) where (table, rest) = keyTable lst keyTable (Null:lst) = keyTable lst -- get rid of Nulls keyTable (Blank:lst) = keyTable lst -- get rid of Blanks -keyTable ((BlockQuote blocks):lst) = ((table1 ++ table2), - ((BlockQuote rest1):rest2)) - where (table1, rest1) = keyTable blocks - (table2, rest2) = keyTable lst -keyTable ((Note ref blocks):lst) = ((table1 ++ table2), - ((Note ref rest1):rest2)) - where (table1, rest1) = keyTable blocks - (table2, rest2) = keyTable lst -keyTable ((OrderedList blockLists):lst) = ((table1 ++ table2), - ((OrderedList rest1):rest2)) - where results = map keyTable blockLists - rest1 = map snd results - table1 = concatMap fst results - (table2, rest2) = keyTable lst -keyTable ((BulletList blockLists):lst) = ((table1 ++ table2), - ((BulletList rest1):rest2)) - where results = map keyTable blockLists - rest1 = map snd results - table1 = concatMap fst results - (table2, rest2) = keyTable lst keyTable (other:lst) = (table, (other:rest)) where (table, rest) = keyTable lst -- cgit v1.2.3