The code given is a fragment. We don't see how $hash0 was made. Can you post a minimal piece of code that will generate the same error that you are getting, when we run it. The above fragment runs just fine and does nothing. If I add strictures and warnings it fails as $hash0 is not defined. Often when going through the process of creating a minimal failing program, you will find enlightenment.
Cheers,
R.
In reply to Re: “Can't use string (”package“) as a HASH ref while ”strict refs"
by Random_Walk
in thread “Can't use string (”package“) as a HASH ref while ”strict refs"
by SunilHn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |