New issue 185 by kos...@gmail.com: Make new-style HTMLTokenizer
Ok, I'll describe the whole problem.
I had a task for creating html sanitizer that keeps iframe's for youtube
videos. I ended up with a sanitizer mixin, that when it sees a youtube
iframe, it starts to skip all new elements until next /iframe.
So since HTMLTokenizer is old-style class -- __init__ in my sanitizer mixin
wouldn't be called and I won't be able to set self.skip_until_iframe =
False in it.
My tests showed that performance is the same.
newstyle_tokenizer.diff 588 bytes