A couple of things here.

This change now makes type(self.expected) to be evaluated once per classtype + 1. While this isn't the end of the world, perhaps it would be better to calculate `type(self.expected)` once and put it in a local variable.

Using map in Python 2.6 & 2.7 means everything will be evaluated. That's not strictly necessary here, since `any` is going to return whenever it comes across anything true. Using `itertools.imap` or generator comprehensions would take advantage of the short circuiting.

This is all relatively unimportant, but I've had performance on the brain.