yoda54 has asked for the wisdom of the Perl Monks concerning the following question:
How would do I access local __DATA__ inside a package?
Thanks
package Test; sub run { while(<Test::DATA>) { print "$_\n"; } } __DATA__ 1 #!/usr/bin/perl use strict; use warnings; use Test; Test::run();
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Using __DATA__ from a package
by Athanasius (Archbishop) on Jun 18, 2013 at 06:18 UTC | |
by poj (Abbot) on Jun 18, 2013 at 07:42 UTC | |
by Lotus1 (Vicar) on Jun 18, 2013 at 13:48 UTC | |
|
Re: Using __DATA__ from a package
by DrHyde (Prior) on Jun 18, 2013 at 11:37 UTC | |
|
Re: Using __DATA__ from a package
by BrowserUk (Patriarch) on Jun 18, 2013 at 04:45 UTC | |
|
Re: Using __DATA__ from a package
by grondilu (Friar) on Jun 18, 2013 at 03:25 UTC | |
by Anonymous Monk on Jun 18, 2013 at 04:01 UTC |