Spot any errors? let me know, but Unleash your pedant politely please.

Thursday, 2 April 2009

Type-Safe Python

Introspection, baby !

if frameType.__class__.__name__ == 'FrameType':
    ...
else:
    raise 'frameType must be an instance of FrameType'

No comments:

Post a Comment