From: Vincent Pit Date: Sat, 27 Dec 2008 11:31:29 +0000 (+0100) Subject: Document the return values of the callbacks X-Git-Tag: v0.27~20 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=b4df0fe613c5d28ab2a82e6f5fdac149013d88fc;p=perl%2Fmodules%2FVariable-Magic.git Document the return values of the callbacks --- diff --git a/lib/Variable/Magic.pm b/lib/Variable/Magic.pm index bad5961..448ea29 100644 --- a/lib/Variable/Magic.pm +++ b/lib/Variable/Magic.pm @@ -324,6 +324,9 @@ In the special case of C magic and when the variable is an array, C<$_[2]> C<$_[2]> is the current key in C, C, C, C and C callbacks, although for C it may just be a copy of the actual key so it's useless to (for example) cast magic on it. C magic also receives the current element (i.e. the value) in C<$_[3]>. +All the callbacks are expected to return an integer, which is passed straight to the perl magic API. +However, only the return value of the C callback currently holds a meaning. + =back # A simple scalar tracer