me_like_perl has asked for the wisdom of the Perl Monks concerning the following question:
off course the above works but what would be the correct syntax if i would want to do something like that with a variable package name like below :eval( "use sy::$c->{id}" ); print Dumper ( %{sy::c1::capability} );
Even a simple link would do if i could find the info there Many Thx for the help ...print Dumper ( %{sy::$packname::capability }
Update:Thank you everyone for your help
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Dynamic package name (?!)
by moritz (Cardinal) on Feb 07, 2011 at 15:05 UTC | |
by me_like_perl (Initiate) on Feb 07, 2011 at 15:15 UTC | |
by moritz (Cardinal) on Feb 07, 2011 at 15:24 UTC | |
|
Re: Dynamic package name (?!)
by chromatic (Archbishop) on Feb 07, 2011 at 17:00 UTC | |
|
Re: Dynamic package name (?!)
by Anonymous Monk on Feb 07, 2011 at 15:31 UTC | |
by me_like_perl (Initiate) on Feb 08, 2011 at 08:49 UTC | |
|
Re: Dynamic package name (?!)
by Anonymous Monk on Feb 07, 2011 at 15:15 UTC | |
|
Re: Dynamic package name (?!)
by pemungkah (Priest) on Feb 09, 2011 at 23:58 UTC | |
|
Re: Dynamic package name (?!)
by CountZero (Bishop) on Feb 07, 2011 at 14:57 UTC | |
by me_like_perl (Initiate) on Feb 07, 2011 at 14:59 UTC | |
by CountZero (Bishop) on Feb 07, 2011 at 19:23 UTC |