in reply to Re^2: Parameters not in order by using Config:Tiny
in thread Parameters not in order by using Config::Tiny
OK, so you have options for your options based on things, like maybe the date. I must be dense today, but I can't see how sorting would help unless you have cleverly named your sections (as in your example) and then do:
my $template; while ( I am looping through Sections) { next unless first half of name is 'until'; next unless date in second half of name hasn't passed yet; $template = this_Section->{TEMPLATE}; last; }
But for the OP, how would
foreach $ini_sect ( sort keys %ini_file ) { %$ini_sect = %{ $ini_file{$ini_sect} }; }
be any better than
foreach $ini_sect ( keys %ini_file ) { %$ini_sect = %{ $ini_file{$ini_sect} }; }
??
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Parameters not in order by using Config:Tiny
by Corion (Patriarch) on Jul 06, 2015 at 15:11 UTC |