New submission from Chen ZHANG: Since the usage of isinstance could be "isinstance(1, (int, float))", I'm wondering why it doesn't accept "[int, float]", if I do so, it would raise TypeError saying "arg 2 must be a type or tuple of types". What's the difference in effect between a tuple and a list here? (I know a tuple is immutable, but I think it doesn't matter when passing some other types of non-string iterables(yielding strings), am I right?
---------- components: Library (Lib) messages: 209519 nosy: Chen.ZHANG priority: normal severity: normal status: open title: Could method "isinstance" take a list as parameter? type: enhancement _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue20415> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com