Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
`parser` seems like it can be an `HTMLParser. There's code in the wild that does this without obviously being wrong. As far as I can tell from the lxml Cython source, `parser` is a `_Baseparser`. I wasn't sure if the `iterparse` class ought to be allowed here too. I erred on the side of caution. It's possible for this function to return None, if the parser has `recover=True`. I couldn't find a good way to express this without affecting every other call to `fromstring`. (Perhaps one could make the Parser generic over some kind of `Recoverable` indicator type... but that seemed like overkill) Resolves lxml#63.
- Loading branch information