use Data::DumperAdd a semicolon:
use Data::Dumper;
B::Deparse can help to get a little more information (Tip #6 from Basic debugging checklist):
Here it shows that my %count looks like it's being passed to Data::Dumper.$ perl -MO=Deparse test.pl Global symbol "%count" requires explicit package name at test.pl line +11. Global symbol "%count" requires explicit package name at test.pl line +14. test.pl had compilation errors. use Data::Dumper (my %count); use warnings; use strict 'refs'; open FILE, 'test.log'; while (defined($_ = <FILE>)) { my(@fields) = split(' ', $_, 0); 'count'->{$fields[1]}++; } print Dumper(\(%{'count'}));
In reply to Re: Help on variable declaration with "use strict "
by toolic
in thread Help on variable declaration with "use strict "
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |