stubtest: improve handling of special dunders (#9626)
Reckon with the fact that __init_subclass__ and __class_getitem__ are
special cased to be implicit classmethods.
Fix some false negatives for other special dunders.
Co-authored-by: hauntsaninja <>