in reply to Re^2: predeclaring subs problems
in thread predeclaring subs problems

First, don't post code you didn't run. You're missing the word "sub" in a couple of places.

Secondly, since the error is in Module2, it would help if you could show it.

I suspect you did

use Module qw(:all); package Module2; ... cook(); ...
when you should have done
package Module2; use Module qw(:all); ... cook(); ...
The former imports everything into the wrong package.