The trick is to wrap the method invocation in a subroutine:
my $handler = MIS_SAX_Parser->new(sub { $cb->printit });
Basically, you're creating a curried version of your method invocation, since $cb->printit is to Perl mostly MIS_PrintStatus::printit( $cb ).
In reply to Re: Ref to an object instance method
by Corion
in thread Ref to an object instance method
by former33t
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |