Test for the property you are searching, not the class.
package OP; sub has_my_property { return 1; } package BINOP; sub has_my_property { return 0; } package UNOP; sub has_my_property { return 0; }
etc. The Test::MockObject object can claim to have the property if it so desires.
I can't help you further without knowing why you need to know if it's exactly an OP or not.
In reply to Re: ISA but no farther?
by ikegami
in thread ISA but no farther?
by diotalevi
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |