perl -MStorable=retrieve -e '@ARGV = "-" unless @ARGV; print +(retrieve $_)->foo for @ARGV' filename