Actually tracking down diagnostic messages is one thing where people Really Should use the online documentation. They change a lot from release to release, and not knowing how to get the ones for your version of Perl can seriously confuse. (There was a thread once involving our where that came up, there was nothing in 5.003 and hence Camel 2, it exits in 5.6 and hence Camel 3, but in 5.005 the word was reserved and generated a warning that confused some...)

In this case you first type:

perldoc perldiag
then type:
/Useless use
then type "n" until you get to the right message. If you go too far type "1G"

Where I said "Useless use" above I just wanted some part of the fixed error message. Usually it isn't hard to guess, but sometimes you will need to try twice to figure out what it should be.

That will give you messages that are appropriate for your version of Perl.


In reply to Re (tilly) 2: useless use of a constant in a void context? by tilly
in thread useless use of a constant in a void context? by princepawn

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.