support html5lib>=0.99