Just to clarify mifflin's answer a bit, note that objects are by definition already references. Passing them to a subroutine is always pass-by-reference. All you've done is added another layer of referencing -- which will use more memory, not less.
As for the syntax, you should be able to access the inner reference with $$ref->parts(), but the real answer is probably to set a limit on the number of nested attachments. I can't imagine how many it would take to exhaust your system's memory to the point of causing perl to crash, but I think that's probably too many. 8^)
In reply to Re: Passing References to Subroutines
by revdiablo
in thread Passing References to Subroutines
by ketema
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |