in reply to Please explain: A hash of file handles peculiarity

Perl demands that whatever appears inside the <> operator be a simple scalar value -- no subscripts or expressions allowed. You've "stumbled" upon a common workaround for this limitation. Another one would be to use a module like IO::Handle or IO::File, so that you can use the readline method of the objects instead.

japhy -- Perl and Regex Hacker
  • Comment on Re: Please explain: A hash of file handles peculiarity