diff --git a/xml-conduit/src/Text/XML/Stream/Parse.hs b/xml-conduit/src/Text/XML/Stream/Parse.hs index 6112c5c..93c450a 100644 --- a/xml-conduit/src/Text/XML/Stream/Parse.hs +++ b/xml-conduit/src/Text/XML/Stream/Parse.hs @@ -587,6 +587,8 @@ parseIdent = valid '/' = False valid ';' = False valid '#' = False + valid '[' = False + valid ']' = False valid c = not $ isXMLSpace c parseContent :: ParseSettings diff --git a/xml-conduit/test/unit.hs b/xml-conduit/test/unit.hs index 092432d..eab1eb3 100644 --- a/xml-conduit/test/unit.hs +++ b/xml-conduit/test/unit.hs @@ -735,7 +735,7 @@ testRenderComments =do resolvedInline :: Assertion resolvedInline = do - Res.Document _ root _ <- return $ Res.parseLBS_ Res.def "]>&bar;" + Res.Document _ root _ <- return $ Res.parseLBS_ Res.def "]>&bar;" root @?= Res.Element "foo" Map.empty [Res.NodeContent "baz"] Res.Document _ root2 _ <- return $ Res.parseLBS_ Res.def "]>" root2 @?= Res.Element "foo" (Map.singleton "bar" "baz") []