asserting types

Mick vsl6 at paradise.net.nz
Fri Apr 20 20:24:34 EDT 2001


What is the cleanest way to assert a class type?  for example if one has a
function that uses a particular class object then what is the nicest way to
assert within the function that the class is of the correct type?  I assume
this is simple, so I guess more the question is this the wrong way to think?
should I be trying to organise things in a different way so as to generate
"compile" time errors?

regards
Mick





More information about the Python-list mailing list