# HG changeset patch # User Jeff Hammel # Date 1392782982 28800 # Node ID 870af8d515525ba30bb001b67af7c3360270730a # Parent 89a72399286ba081144df00ac01edfd8aade980e STUB: python/example/classes.py diff -r 89a72399286b -r 870af8d51552 python/example/classes.py --- a/python/example/classes.py Mon Feb 17 17:33:23 2014 -0800 +++ b/python/example/classes.py Tue Feb 18 20:09:42 2014 -0800 @@ -7,9 +7,13 @@ class A: pass -tests = ["issubclass(A, A)"] +tests = ["issubclass(A(), A)", + "issubclass(A, A)"] if __name__ == '__main__': for test in tests: print ("? {}".format(test)) - print (eval(test)) + try: + print (eval(test)) + except Exception as e: + print ('{}'.format(repr(e)))