OK, so forget uplevel and just reimplement what base actually does. It's a pity base.pm didn't do it right from the start. If you're going to act like "use" then you should do it properly.

As for a just a few characters, I really have a problem with that. I don't mind a few characters extra for some things but this is perfect case of when I do mind because the few characters are a repetition of information (not just, say, some extra syntax).

That means that if I need to change the base class, I need to remember to change both occurrences. This breaks the rule of having 1 source for every piece of information and leads to subtle errors. In this case it's fairly easy to keep them in sync as they're beside each other but in another way that makes it even worse because it would be so easy to fix.


In reply to Re^3: use base 'XYZ' and exporting by fergal
in thread use base 'XYZ' and exporting by japhy

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.