Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Hello clueless newbie,

Glad you found a solution. I just want to comment on this:

#use strict; # made redundant by use 5.014_00 #use warnings; # made redundant by use 5.014_00

The first comment is correct; but the second most certainly is not!

0:23 >perl -e "print $x;" 0:24 >perl -we "print $x;" Name "main::x" used only once: possible typo at -e line 1. Use of uninitialized value $x in print at -e line 1. 0:24 >perl -M5.014 -e "print $x;" Global symbol "$x" requires explicit package name (did you forget to d +eclare "my $x"?) at -e line 1. Execution of -e aborted due to compilation errors. 0:24 >perl -M5.014 -e "my $x; print $x;" 0:24 >perl -M5.014 -we "my $x; print $x;" Use of uninitialized value $x in print at -e line 1. 0:24 >

From use:

use VERSION also lexically enables all features available in the requested version as defined by the feature pragma, disabling any features not in the requested version's feature bundle.... Similarly, if the specified Perl version is greater than or equal to 5.12.0, strictures are enabled lexically as with use strict.

(See feature#FEATURE-BUNDLES for a list of the features associated with each Perl version.) The warnings pragma must be enabled explicitly — either via the lexical use warnings;, which is the preferred method; or via a -w command line switch; or by setting the global $^W variable to a true value (not usually recommended).

Hope that helps,

Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,


In reply to Re^2: How to serialize and deserialize Dios/Object::InsideOut objects? by Athanasius
in thread How to serialize and deserialize Dios/Object::InsideOut objects? by clueless newbie

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chilling in the Monastery: (10)
As of 2024-04-19 08:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found