X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=src%2FMain.hs;h=b81b6f0e25620092672eddaec5bc3868cab00344;hb=988f693ce7f1abb6566e75d539ac312b627c31d5;hp=e1f40267889c9e4a8a4609cb0a7e7bf9c3b47b95;hpb=ee387af8b24654089f13493637efc45bd48a8e41;p=dead%2Fhtsn-import.git diff --git a/src/Main.hs b/src/Main.hs index e1f4026..b81b6f0 100644 --- a/src/Main.hs +++ b/src/Main.hs @@ -23,7 +23,6 @@ import System.IO.Error ( catchIOError ) import Text.XML.HXT.Core ( ArrowXml, IOStateArrow, - SysConfigList, XmlPickler, XmlTree, (>>>), @@ -31,16 +30,10 @@ import Text.XML.HXT.Core ( getAttrl, getText, hasName, - no, readDocument, runX, unpickleDoc, - withPreserveComment, - withRemoveWS, - withSubstDTDEntities, - withValidate, - xpickle, - yes ) + xpickle ) import Backend ( Backend(..) ) import CommandLine ( get_args ) @@ -61,22 +54,7 @@ import qualified TSN.InjuriesDetail as InjuriesDetail ( Listing ( player_listings ), Message ( listings ), PlayerListing ) - - - --- | A list of options passed to 'readDocument' when we parse an XML --- document. We don't validate because the DTDs from TSN are --- wrong. As a result, we don't want to keep useless DTDs --- areound. Thus we disable 'withSubstDTDEntities' which, when --- combined with "withValidate no", prevents HXT from trying to read --- the DTD at all. --- -parse_opts :: SysConfigList -parse_opts = - [ withPreserveComment no, - withRemoveWS yes, - withSubstDTDEntities no, - withValidate no ] +import Xml ( parse_opts ) -- | We put the 'Configuration' and 'XmlTree' arguments last so that