Indeed this is a situation in which turning on warnings would have solved the problem for you:
$ perl -we '%a=($bob => "foo")'
Name "main::a" used only once: possible typo at -e line 1.
Name "main::bob" used only once: possible typo at -e line 1.
Use of uninitialized value in list assignment at -e line 1.
See in particular the last line. But then if had also turned on strict
$ perl -Mstrict -e 'my %a=($bob => "foo")'
Global symbol "$bob" requires explicit package name at -e line 1.
Execution of -e aborted due to compilation errors.
So, to put it briefly: do it! |