in reply to
Re^4: can't import using exporter
in thread can't import using exporter
You're doing this the hard way.
Put each module in a separate file. Use use. Things will magically just work, because that's how they were designed to work.
To make things work your way, you'll have to declare our variables outside of the BEGIN block and then, within a BEGIN block, assign to them. You're going to have a hard time getting things to work by randomly adding braces and blocks and little bits of syntax.