Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Constant subroutine main::C redefined

by Corion (Pope)
on Sep 10, 2012 at 11:51 UTC ( #992733=note: print w/ replies, xml ) Need Help??


in reply to Constant subroutine main::C redefined

perllexwarn "tells" me

no warnings 'redefine';

... but I guess there should be a way to structure your code not to redefine an existing subroutine at all :-).

On Windows (resp. case-insensitive file systems), getting a lot of these for no obvious reason is a sure-fire symptom of loading a module using the wrong case for its name:

use File::Find; # ... and in a code location far away use file::find;


Comment on Re: Constant subroutine main::C redefined
Select or Download Code
Re^2: Constant subroutine main::C redefined
by BrowserUk (Pope) on Sep 10, 2012 at 12:00 UTC
    no warnings 'redefine';

    Doesn't work for constant subroutines

    there should be a way to structure your code not to redefine an existing subroutine at all :-).

    In this case, no.


    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

    RIP Neil Armstrong

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2014-07-11 22:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (235 votes), past polls