If i am reading this correct, what you are trying to do, while possible, is not really a good idea. If you are looking to make
$foo->{key} available via
$foo->key by making dynamic methods, i suggest taking a look at the
AUTOLOAD routine ... as it is made for just such an occasion.
"They shall not overcome. Whoever told them that the truth shall set them free was obviously and grossly unfamiliar with federal law."
-- John Ashcroft