Return a value that is appropriate, logical, and will further the task that you wish to complete.
If you are updating the data of the object, you should always be sure if there is an error, report if back to the caller of the method. This may involve a convention with the return value, ie: returning undef -or- zero and setting $! to something pithy and relevant, or terminating using croak with a descriptive message.
Good luck, -c
In reply to Re: Return $self, but what if I don't wanna?
by chuckbutler
in thread Return $self, but what if I don't wanna?
by asoftware
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |