- ############ test.pl
- use warnings;
- use strict;
- use test;
- print $foo;
- ########### test.pm
- use warnings;
- use strict;
- use Exporter;
- our @ISA = qw(Exporter);
- our @EXPORT = qw($foo);
- our $foo = "test\n";
- 1;
- ####### Meldung
- Global symbol "$foo" requires explicit package name at ./test.pl line 6.
- Execution of ./test.pl aborted due to compilation errors.
Posted by schlicht on Wed 9th Apr 11:46 (modification of post by view diff)
download | new post
Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.