sub func { return ('a' => 'ah', 'b' => 'be') }; #### keys func(); keys ( func() ); keys ( &func() ); #### Type of arg 1 to keys must be hash (not subroutine entry) #### my %hash = func(); keys %hash;