in reply to (Guildenstern ) REx4: Win32::MemoryInfo
in thread Win32::MemoryInfo
Silly trick:
Just put all possible defaults in %default and the user can override any combination they want, and your %allowed check will catch most typos and misunderstandings of the API.my %args = %default, @_; foreach my $arg (keys %args) { unless (exists $allowed{$arg}) { croak("Unrecognized argument '$arg' passed to MemoryStatus."); } }
In Section
Code Catacombs