#2 Array elements undef

closed-fixed
nobody
None
5
2001-11-25
2001-06-16
Anonymous
No

I step through this short program:

while(<>)
{
chomp;
if (not $_) { last; }
@word = split;
print $word[0];
}

After the step "@word = split;", I attempt to view the
value of @word or $word[0], but receive <undef>.
Using ActivePerl 5.6.1 and Perl IDE 0.98 with the
patch for 5.6.1.

Discussion

    • status: open --> pending-later
     
  • Logged In: YES
    user_id=165877

    Up to version 0.9.8 there is a scope resolution problem for
    all variables which aren't defined with "my".
    These variables must be fully qualified to be evaluated by
    the Open Perl IDE Debugger. So, in the example above,
    @main::word should work.

    This bug will be fixed in release 0.9.9.

     
    • status: pending-later --> closed-later
     
    • status: closed-later --> closed-fixed
     
  • Curt Bates
    Curt Bates
    2003-01-06

    Logged In: YES
    user_id=659732

    Hashes also show as undef.