You can do:
my %hash; BEGIN { %hash = (bar => 'value'); } ... [download]
In reply to Re: Mini-rant about 'strict' by ysth in thread Mini-rant about 'strict' by Ovid