@@ -331,7 +331,7 @@ convertingExtraState v a = withSubStateF setVAsExtraState modifyWithA
332 setVAsExtraState = liftAsSuccess $ extractFromState id >>^ replaceExtraState v
332 setVAsExtraState = liftAsSuccess $ extractFromState id >>^ replaceExtraState v
333 modifyWithA = keepingTheValue (moreState ^>> a)
333 modifyWithA = keepingTheValue (moreState ^>> a)
334− >>^ spreadChoice >>?§ flip replaceExtraState
334+ >>^ spreadChoice >>?% flip replaceExtraState
336-- | First sets the extra state to the new value. Then produces a new
336-- | First sets the extra state to the new value. Then produces a new
337-- extra state with a converter that uses the new state. Finally, the
337-- extra state with a converter that uses the new state. Finally, the
@@ -413,14 +413,14 @@ elemName :: (NameSpaceID nsID)
413 -> XMLConverter nsID extraState x XML.QName
413 -> XMLConverter nsID extraState x XML.QName
414elemName nsID name = lookupNSiri nsID
414elemName nsID name = lookupNSiri nsID
415 &&& lookupNSprefix nsID
415 &&& lookupNSprefix nsID
416− >>§ XML.QName name
416+ >>% XML.QName name
418-- | Checks if a given element matches both a specified namespace id
418-- | Checks if a given element matches both a specified namespace id
419-- and a specified element name
419-- and a specified element name
420elemNameIs :: (NameSpaceID nsID)
420elemNameIs :: (NameSpaceID nsID)
421 => nsID -> ElementName
421 => nsID -> ElementName
422 -> XMLConverter nsID extraState XML.Element Bool
422 -> XMLConverter nsID extraState XML.Element Bool
423−elemNameIs nsID name = keepingTheValue (lookupNSiri nsID) >>§ hasThatName
423+elemNameIs nsID name = keepingTheValue (lookupNSiri nsID) >>% hasThatName
424 where hasThatName e iri = let elName = XML.elName e
424 where hasThatName e iri = let elName = XML.elName e
425 in XML.qName elName == name
425 in XML.qName elName == name
426 && XML.qURI elName == iri
426 && XML.qURI elName == iri
@@ -461,8 +461,8 @@ currentElemIs'' nsID name = ( (getCurrentElement >>^ XML.elName >>>
461 (XML.qName >>^ (&&).(== name) )
461 (XML.qName >>^ (&&).(== name) )
463 (XML.qIRI >>^ (==) )
463 (XML.qIRI >>^ (==) )
464− ) >>§ (.)
464+ ) >>% (.)
465− ) &&& lookupNSiri nsID >>§ ($)
465+ ) &&& lookupNSiri nsID >>% ($)
@@ -487,7 +487,7 @@ findChildren :: (NameSpaceID nsID)
487 -> XMLConverter nsID extraState x [XML.Element]
487 -> XMLConverter nsID extraState x [XML.Element]
488findChildren nsID name = elemName nsID name
488findChildren nsID name = elemName nsID name
489 &&& getCurrentElement
489 &&& getCurrentElement
490− >>§ XML.findChildren
490+ >>% XML.findChildren
493filterChildren :: (XML.Element -> Bool)
493filterChildren :: (XML.Element -> Bool)
@@ -508,7 +508,7 @@ findChild' :: (NameSpaceID nsID)
508 -> XMLConverter nsID extraState x (Maybe XML.Element)
508 -> XMLConverter nsID extraState x (Maybe XML.Element)
509findChild' nsID name = elemName nsID name
509findChild' nsID name = elemName nsID name
510 &&& getCurrentElement
510 &&& getCurrentElement
511− >>§ XML.findChild
511+ >>% XML.findChild
514findChild :: (NameSpaceID nsID)
514findChild :: (NameSpaceID nsID)
@@ -596,7 +596,7 @@ isThatTheAttrValue :: (NameSpaceID nsID)
596isThatTheAttrValue nsID attrName
596isThatTheAttrValue nsID attrName
597 = keepingTheValue
597 = keepingTheValue
598 (findAttr nsID attrName)
598 (findAttr nsID attrName)
599− >>§ right.(==)
599+ >>% right.(==)
601-- | Lookup value in a dictionary, fail if no attribute found or value
601-- | Lookup value in a dictionary, fail if no attribute found or value
602-- not in dictionary
602-- not in dictionary
@@ -669,7 +669,7 @@ findAttr' :: (NameSpaceID nsID)
669 -> XMLConverter nsID extraState x (Maybe AttributeValue)
669 -> XMLConverter nsID extraState x (Maybe AttributeValue)
670findAttr' nsID attrName = elemName nsID attrName
670findAttr' nsID attrName = elemName nsID attrName
671 &&& getCurrentElement
671 &&& getCurrentElement
672− >>§ XML.findAttr
672+ >>% XML.findAttr
674-- | Return value as string or fail
674-- | Return value as string or fail
675findAttr :: (NameSpaceID nsID)
675findAttr :: (NameSpaceID nsID)
@@ -787,7 +787,7 @@ prepareIteration :: (NameSpaceID nsID)
787 -> XMLConverter nsID extraState b [(b, XML.Element)]
787 -> XMLConverter nsID extraState b [(b, XML.Element)]
788prepareIteration nsID name = keepingTheValue
788prepareIteration nsID name = keepingTheValue
789 (findChildren nsID name)
789 (findChildren nsID name)
790− >>§ distributeValue
790+ >>% distributeValue
792-- | Applies a converter to every child element of a specific type.
792-- | Applies a converter to every child element of a specific type.
793-- Collects results in a 'Monoid'.
793-- Collects results in a 'Monoid'.
@@ -877,9 +877,9 @@ makeMatcherE nsID name c = ( second (
877 elemNameIs nsID name
877 elemNameIs nsID name
878 >>^ bool Nothing (Just tryC)
878 >>^ bool Nothing (Just tryC)
880− >>§ (<|>)
880+ >>% (<|>)
881 ) &&&^ snd
881 ) &&&^ snd
882− where tryC = (fst ^&&& executeThere c >>§ recover) &&&^ snd
882+ where tryC = (fst ^&&& executeThere c >>% recover) &&&^ snd
884-- Helper function: The @c@ is actually a converter that is to be selected by
884-- Helper function: The @c@ is actually a converter that is to be selected by
885-- matching XML content to the first two parameters.
885-- matching XML content to the first two parameters.
@@ -899,14 +899,14 @@ makeMatcherC nsID name c = ( second ( contentToElem
899 >>^ bool Nothing (Just cWithJump)
899 >>^ bool Nothing (Just cWithJump)
902− >>§ (<|>)
902+ >>% (<|>)
903 ) &&&^ snd
903 ) &&&^ snd
904 where cWithJump = ( fst
904 where cWithJump = ( fst
905 ^&&& ( second contentToElem
905 ^&&& ( second contentToElem
906 >>> spreadChoice
906 >>> spreadChoice
907 ^>>? executeThere c
907 ^>>? executeThere c
909− >>§ recover)
909+ >>% recover)
911 contentToElem :: FallibleXMLConverter nsID extraState XML.Content XML.Element
911 contentToElem :: FallibleXMLConverter nsID extraState XML.Content XML.Element
912 contentToElem = arr $ \e -> case e of
912 contentToElem = arr $ \e -> case e of