From: Vincent Pit Date: Sat, 28 Feb 2009 19:47:42 +0000 (+0100) Subject: clear magic only applies to arrays and hashes X-Git-Tag: v0.32~2 X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2FVariable-Magic.git;a=commitdiff_plain;h=4affb8304508fab43fb2247aa6d4d842c5fb82f2 clear magic only applies to arrays and hashes --- diff --git a/lib/Variable/Magic.pm b/lib/Variable/Magic.pm index 0ddcaec..59900d0 100644 --- a/lib/Variable/Magic.pm +++ b/lib/Variable/Magic.pm @@ -125,7 +125,7 @@ The callback has then to return the length as an integer. C -This magic is invoked when the variable is reset, such as when an array is emptied. +This magic is invoked when a container variable is reset, i.e. when an array or a hash is emptied. Please note that this is different from undefining the variable, even though the magic is called when the clearing is a result of the undefine (e.g. for an array, but actually a bug prevent it to work before perl 5.9.5 - see the L). =item *