@@ -13,6 +13,7 @@ examples :: [(Bool, BS.ByteString)]
1313examples =
1414 [(True, "<test id='bob'>here<extra/>there</test>")
1515 ,(True, "<test /><close />")
16+ ,(True, "<test /><!-- comment > --><close />")
1617 ,(True, "<test id=\"bob value\" another-attr=\"test with <\">here </test> more text at the end<close />")
1718 ,(False, "<test></more>")
1819 ,(False, "<test")
@@ -58,5 +59,5 @@ rerender = inside
5859 | otherwise = error "Invalid name"
5960 validAttr x | BS.notElem '\"' x = x
6061 | otherwise = error "Invalid attribute"
61− validStr x | BS.notElem '<' x = x
62+ validStr x | BS.notElem '<' x || BS.isInfixOf "<!--" x = x
6263 | otherwise = error $ show ("Invalid string", x)