use strict; use warnings; package B; our $foo = 3; package main; print $B::foo, "\n";
If you don't want the $B::foo notation, have a look at Exporter
In reply to Re: Variable access across packages?
by moritz
in thread Variable access across packages?
by porta
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |