Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: global variable initialization inside try{}

by ikegami (Pope)
on Apr 09, 2009 at 15:39 UTC ( #756640=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    
    f();
    g();
    
  2. or download this
    >perl589\bin\perl test.pl
    Use of uninitialized value in concatenation (.) or string at test.pl l
    +ine 9.
    ...
    >perl5100\bin\perl test.pl
    f: test
    g: test
    
  3. or download this
    >perl589\bin\perl -wle"{ my $s='test'; sub f { print 's: ', eval '$s' 
    +} } f()"
    Use of uninitialized value in print at -e line 1.
    ...
    Variable "$s" is not available at (eval 1) line 2.
    Use of uninitialized value in print at -e line 1.
    s:
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://756640]
help
Chatterbox?
[1nickt]: ugh, buying a computer is hard for an old person
[stevieb]: How do you mean?
[1nickt]: They assume that I want things I don;t and don;t provide things I do want. Looking for a 17" laptop with 4k (even 3K display) and full numeric-pad keyboard.
[1nickt]: They assume that if I want a 17" monitor I could not possibly want 4k screen
[1nickt]: They assume I do not need a DVD drive
[1nickt]: Heh, or they assume that if I want all that I am a "gamer" and I must want red backlighting for the keyboards and that I will pay $3500 ...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2017-03-26 18:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (315 votes). Check out past polls.