packages feed

hxt-tagsoup 9.1.2 → 9.1.3

raw patch · 3 files changed

+13/−3 lines, 3 files

Files

hxt-tagsoup.cabal view
@@ -1,6 +1,6 @@ -- arch-tag: Haskell XML Toolbox main description file Name:           hxt-tagsoup-Version:        9.1.2+Version:        9.1.3 Synopsis:       TagSoup parser for HXT Description:    The Tagsoup interface for the HXT lazy HTML parser. License:        OtherLicense
src/Text/XML/HXT/Arrow/TagSoupInterface.hs view
@@ -44,7 +44,7 @@ > import Text.HXT.XML.TagSoup > ... >-> readDocument [ withExpat ] "some-file.xml"+> readDocument [ withTagSoup ] "some-file.xml" > ...  reads the given document and parses it with the lazy tagsoup parser.
src/Text/XML/HXT/Parser/TagSoup.hs view
@@ -2,7 +2,7 @@  {- |    Module     : Text.XML.HXT.Parser.TagSoup-   Copyright  : Copyright (C) 2005-2008 Uwe Schmidt+   Copyright  : Copyright (C) 2005-2014 Uwe Schmidt    License    : MIT     Maintainer : Uwe Schmidt (uwe@fh-wedel.de)@@ -23,6 +23,9 @@  -- ------------------------------------------------------------ +import Control.Applicative              ( Applicative(..) )+import Control.Monad                    ( liftM, ap )+ import Data.Char                        ( toLower                                         ) import Data.Char.Properties.XMLCharProps( isXmlSpaceChar@@ -75,6 +78,13 @@ type State              = Tags  newtype Parser a        = P { parse :: State -> (a, State)}++instance Functor Parser where+    fmap = liftM++instance Applicative Parser where+    pure  = return+    (<*>) = ap  instance Monad Parser where     return x    = P $ \ ts -> (x, ts)