Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^2: Testing for valid package names

by boftx (Chaplain)
on Nov 25, 2013 at 21:20 UTC ( #1064301=note: print w/ replies, xml ) Need Help??


in reply to Re: Testing for valid package names
in thread Testing for valid package names

Thanks!

I thought about numbers as the first char, but that is legal for filenames so far as I know. I am still mulling that over.

I wasn't aware of that Perl::Critic rule (not surprising) but the POD doesn't mention anything about the legal character set, only that a single-quote "'" should not be used even though it is a valid substitute for the double-colon '::' separator.

It helps to remember that the primary goal is to drain the swamp even when you are hip-deep in alligators.


Comment on Re^2: Testing for valid package names
Re^3: Testing for valid package names
by LanX (Canon) on Nov 25, 2013 at 21:24 UTC
    IIRC, no (non-special) identifier is allowed to start with a number.

    Though I'm sure one can trick to enter them as key value pairs into the stash.

    Cheers Rolf

    ( addicted to the Perl Programming Language)

      You're right about numbers up front. I should have tried this to begin with:

      [jim@krakatoa perl]$ cat use23Skidoo.pl #!/usr/bin/perl -T use 5.008_008; use strict; use warnings FATAL => 'all'; use 23Skidoo; exit; __END__ [jim@krakatoa perl]$ ./use23Skidoo.pl syntax error at ./use23Skidoo.pl line 8, near "use 23" Execution of ./use23Skidoo.pl aborted due to compilation errors. [jim@krakatoa perl]$
      It helps to remember that the primary goal is to drain the swamp even when you are hip-deep in alligators.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1064301]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2014-07-26 09:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (175 votes), past polls