General Type Checks (int, str, tuple, etc.)

2006-01-28 Thread Fabian Steiner
Hello! So far, I am using something like »if isinstance(var, int):« to determine, whether var's value is an integer. Now I would like to know if there is any better possibility to do such general checks or may a construct with isinstance() even fail in certain cases? Cheers, Fabian --

Re: General Type Checks (int, str, tuple, etc.)

2006-01-28 Thread Scott David Daniels
Fabian Steiner wrote: Hello! So far, I am using something like »if isinstance(var, int):« to determine, whether var's value is an integer. Now I would like to know if there is any better possibility to do such general checks or may a construct with isinstance() even fail in certain