in reply to Re^3: Converting Hashes to Objects
in thread Converting Hashes to Objects
keys must be valid Perl identifiers if accessed via this module.
Good point, thanks, done.
Other methods can still be called with trickery, but of course that's not really the point of this module :-)
use Util::H2O; my $o = h2o { '$%@.?' => 123 }; my $meth = '$%@.?'; print $o->$meth; # prints 123
|
|---|