in reply to Re: inconsistent module access
in thread inconsistent module access
use feature 'switch'; no warnings 'experimental'; $m = 'test'; given ( $m ) { when ('test') { test::Get() }; } package test; sub Get { require IO::All; $data = io(); } 1;
FWIW, changing the call to io()% perl t.pl Undefined subroutine &test::io called at t.pl line 11.
Results in a different error.$data = IO::All::io()
Can't call method "_package" on an undefined value at /usr/share/perl5 +/vendor_perl/IO/All.pm line 63.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: inconsistent module access
by haukex (Archbishop) on Jun 25, 2022 at 06:28 UTC | |
Re^3: inconsistent module access (require vs use)
by LanX (Saint) on Jun 25, 2022 at 10:18 UTC |