summaryrefslogtreecommitdiffstats
path: root/perl_checker.src
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2004-11-26 11:08:33 +0000
committerPascal Rigaux <pixel@mandriva.com>2004-11-26 11:08:33 +0000
commit0f3c9e4443546b082d93eacd1dd6869b21181094 (patch)
treed550a717635f0ed49de4760f9c861eeb1e4294ce /perl_checker.src
parent56e3fd19f9d407384e0785d6200ed91779ab78e0 (diff)
downloadperl-MDK-Common-0f3c9e4443546b082d93eacd1dd6869b21181094.tar
perl-MDK-Common-0f3c9e4443546b082d93eacd1dd6869b21181094.tar.gz
perl-MDK-Common-0f3c9e4443546b082d93eacd1dd6869b21181094.tar.bz2
perl-MDK-Common-0f3c9e4443546b082d93eacd1dd6869b21181094.tar.xz
perl-MDK-Common-0f3c9e4443546b082d93eacd1dd6869b21181094.zip
don't "double quotes are unneeded" for "@m3[1..$#m3]"
Diffstat (limited to 'perl_checker.src')
-rw-r--r--perl_checker.src/parser_helper.ml3
1 files changed, 2 insertions, 1 deletions
diff --git a/perl_checker.src/parser_helper.ml b/perl_checker.src/parser_helper.ml
index 7c61f1b..0376cbb 100644
--- a/perl_checker.src/parser_helper.ml
+++ b/perl_checker.src/parser_helper.ml
@@ -1136,7 +1136,8 @@ let to_String parse strict { any = l ; pos = pos } =
if ident <> "!" && strict then warn [Warn_suggest_simpler] pos (sprintf "%s is better written without the double quotes" (variable2s(I_scalar, ident)))
| [ "", List [Deref(I_hash, _)]] ->
warn [Warn_traps] pos "don't use a hash in string context"
- | [ "", List [Deref(I_array, _)]] ->
+ | [ "", List [Deref(I_array, _)]]
+ | [ "", List [Deref_with(I_array, I_array, _, _)]] -> (* for slices like: "@m3[1..$#m3]" *)
()
| [("", _)] ->
if strict then warn [Warn_suggest_simpler] pos "double quotes are unneeded"