in reply to using an object as a variable type

You might want to read up on perldoc attributes and Attribute-Handlers.

hth, p

Ordinary morality is for ordinary people. -- Aleister Crowley