/tags/rel-1.3.35/Examples/test-suite/python/overload_subtype_runme.py
# · Python · 11 lines · 7 code · 4 blank · 0 comment · 2 complexity · 054d025bcf99c4ff5f9890954cdec89e MD5 · raw file
- from overload_subtype import *
- f = Foo()
- b = Bar()
- if spam(f) != 1:
- raise RuntimeError, "foo"
- if spam(b) != 2:
- raise RuntimeError, "bar"