[Zope] type in python methods

Evan Simpson evan@4-am.com
Thu, 11 Jan 2001 09:49:11 -0500


From: Juan Carlos Coruņa <jcoruna@umd.es>
> How can I compare the type of 2 variables in a python method?
>
> The instruction "if type(var1) == type(var2): ...." doesn't work.

_.same_type(var1, var2) should do it. (Without the "_." in Scripts).

Cheers,

Evan @ digicool & 4-am