in reply to Re^5: read a hash from a file
in thread read a hash from a file

It works! You are a genuis! Is there anyway to do it without using the intermediary %data ?

Replies are listed 'Best First'.
Re^7: read a hash from a file
by hdb (Monsignor) on Apr 16, 2013 at 07:29 UTC

    Try this:

    my $record = REC->new( map{ s/#.*//; s/^\s+//; s/\s+$//; m/(.*?)\s*=\s*(.*)/; } read_file($file) );