summaryrefslogtreecommitdiffstats
path: root/perl_checker.src/parser_helper.ml
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2004-10-14 04:58:40 +0000
committerPascal Rigaux <pixel@mandriva.com>2004-10-14 04:58:40 +0000
commitb5c54309bae69c9c0c8fd02245a79b2da468464e (patch)
treea8776ae4fe5d57bc58d1a4c92744f3a1915746c5 /perl_checker.src/parser_helper.ml
parent0bb82649ff6ce4a7c7cde745c51a5e3ea61c5b2f (diff)
downloadperl_checker-b5c54309bae69c9c0c8fd02245a79b2da468464e.tar
perl_checker-b5c54309bae69c9c0c8fd02245a79b2da468464e.tar.gz
perl_checker-b5c54309bae69c9c0c8fd02245a79b2da468464e.tar.bz2
perl_checker-b5c54309bae69c9c0c8fd02245a79b2da468464e.tar.xz
perl_checker-b5c54309bae69c9c0c8fd02245a79b2da468464e.zip
- add char_quote (to help emacs caml mode)
- change prototype of str_begins_with
Diffstat (limited to 'perl_checker.src/parser_helper.ml')
-rw-r--r--perl_checker.src/parser_helper.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl_checker.src/parser_helper.ml b/perl_checker.src/parser_helper.ml
index 230daf8..c317f98 100644
--- a/perl_checker.src/parser_helper.ml
+++ b/perl_checker.src/parser_helper.ml
@@ -728,8 +728,8 @@ let cook_call_op op para pos =
| "or", [ List [ Deref(I_scalar, id) ]; List [ Call_op("=", [ Deref(I_scalar, id_); _], _) ] ] when is_same_fromparser id id_ ->
warn_rule "\"$foo or $foo = ...\" can be written \"$foo ||= ...\""
- | "and", [ cond ; expr ] -> check_My_under_condition "replace \"<cond> and my $foo = ...\" with \"my $foo = <cond> && ...\"" expr
- | "or", [ cond ; expr ] -> check_My_under_condition "replace \"<cond> or my $foo = ...\" with \"my $foo = !<cond> && ...\"" expr
+ | "and", [ _cond ; expr ] -> check_My_under_condition "replace \"<cond> and my $foo = ...\" with \"my $foo = <cond> && ...\"" expr
+ | "or", [ _cond ; expr ] -> check_My_under_condition "replace \"<cond> or my $foo = ...\" with \"my $foo = !<cond> && ...\"" expr
| _ -> ());