The method documentation was in the wrong section. For the next release, it will move from "Constructors" to "Internals". The right way to open a file, and create it if is doesn't exist yet is very file-open like:
 my $mbox = Mail::Box::Mbox->new(folder => $f,
   access => 'rw', create => 1);
Besides, if you create a message, you always create a Mail::Message, not some Mail::Box::Message, because Mail::Box::Message have some knowledge about location in them, where the message you have created has none yet. It gets a location at $f->addMessage($msg), and will change type at that moment (in this case into a Mail::Box::Mbox::Message).

In reply to Re^2: Can't use string ("MODULE") as a HASH ref while "strict refs" in use by markov
in thread Can't use string ("MODULE") as a HASH ref while "strict refs" in use by m5m5m

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.