Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Almost certainly a module documentation issueby dd-b (Monk) |
on Oct 13, 2017 at 21:37 UTC ( [id://1201350]=perlquestion: print w/replies, xml ) | Need Help?? |
dd-b has asked for the wisdom of the Perl Monks concerning the following question: The Email::Sender::Transport::Print module has very sparse documentation. It does say you can pass a file-handle object in as the attribute "fh". Looking at other Email::Sender::Transport implementations, it appears to me that passing a hash to new with the attributes as name/value pairs is the way it's done (there's a rather startlingly complete shortage of examples of Email::Sender::Transport::Print usage on the web). The code is:
($transport is declared outside the bit quoted, but it is declared.) When I do that, I get the error "isa check for "fh" failed: GLOB(0x806897840) is not blessed". This seems to imply that it noticed that I was in fact passing something as attribute fh, at least! In the debugger, it seems to me that $sm, the thing passed in as the value of attribute fh, is in fact blessed.
I am now wondering WTF. A preliminary attempt to look at the source code of the module foundered; it appears there is none, it's generated on-the-fly using moo or something? Which I'm not familiar with, and while in theory I could study it up and then figure out for sure what's expected, that's starting to look like a large amount of work. Ideas?
Back to
Seekers of Perl Wisdom
|
|