Subject: | RequireInterpolationOfMetachars allow overload.pm deref names |
Date: | Sun, 17 Aug 2008 10:54:40 +1000 |
To: | bug-perl-critic [...] rt.cpan.org |
From: | Kevin Ryde <user42 [...] zip.com.au> |
It'd be good if RequireInterpolationOfMetachars allowed '@{}' and '${}'
which overload.pm takes to express overloaded dereferencing. I think
they're unlikely to otherwise occur as the sort of error
RequireInterpolation aims to catch.
perlcritic --single-policy=RequireInterpolation overload.pl
=>
String *may* require interpolation at line 2, column 3. See page 51 of PBP. (Severity: 1)
String *may* require interpolation at line 3, column 3. See page 51 of PBP. (Severity: 1)
use overload
'@{}' => \&my_arrayize,
'${}' => \&my_deref;