This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5d8673b
)
op.c: ck_grep does not need to check num of args
author
Father Chrysostomos
<sprout@cpan.org>
Sat, 14 Jul 2012 19:28:15 +0000
(12:28 -0700)
committer
Father Chrysostomos
<sprout@cpan.org>
Sun, 15 Jul 2012 00:35:32 +0000
(17:35 -0700)
It calls ck_fun first, which does the same check, so it is
unnecessary.
op.c
patch
|
blob
|
blame
|
history
diff --git
a/op.c
b/op.c
index
acea933
..
b5a78d5
100644
(file)
--- a/
op.c
+++ b/
op.c
@@
-8622,8
+8622,6
@@
Perl_ck_grep(pTHX_ OP *o)
}
kid = cLISTOPo->op_first->op_sibling;
- if (!kid || !kid->op_sibling)
- return too_few_arguments_pv(o,OP_DESC(o), 0);
for (kid = kid->op_sibling; kid; kid = kid->op_sibling)
op_lvalue(kid, OP_GREPSTART);