summaryrefslogtreecommitdiff
path: root/perly.y
diff options
context:
space:
mode:
authorDagfinn Ilmari Mannsåker <ilmari@ilmari.org>2013-06-27 16:48:36 +0100
committerRicardo Signes <rjbs@cpan.org>2013-12-22 13:28:20 -0500
commit8c74b41425572faeb638f1269025b59d0785794f (patch)
tree968acdd55f7bc4c12ad7784d21ba7a19389f9014 /perly.y
parent919ec23b10e41ed5c6aaf77a8ae3d2f7ef279f1b (diff)
downloadperl-8c74b41425572faeb638f1269025b59d0785794f.tar.gz
Remove support for "do SUBROUTINE(LIST)"
It's been deprecated (and emitting a warning) since Perl v5.0.0, and support for it consitutes nearly 3% of the grammar.
Diffstat (limited to 'perly.y')
-rw-r--r--perly.y43
1 files changed, 0 insertions, 43 deletions
diff --git a/perly.y b/perly.y
index b947a179a6..2d8b599cb1 100644
--- a/perly.y
+++ b/perly.y
@@ -1120,49 +1120,6 @@ termdo : DO term %prec UNIOP /* do $filename */
{ $$ = newUNOP(OP_NULL, OPf_SPECIAL, op_scope($2));
TOKEN_GETMAD($1,$$,'D');
}
- | DO subname '(' ')' /* do somesub() */
- { $$ = newUNOP(OP_ENTERSUB,
- OPf_SPECIAL|OPf_STACKED,
- op_prepend_elem(OP_LIST,
- scalar(newCVREF(
- (OPpENTERSUB_AMPER<<8),
- scalar($2)
- )),(OP*)NULL)); dep();
- TOKEN_GETMAD($1,$$,'o');
- TOKEN_GETMAD($3,$$,'(');
- TOKEN_GETMAD($4,$$,')');
- }
- | DO subname '(' expr ')' /* do somesub(@args) */
- { $$ = newUNOP(OP_ENTERSUB,
- OPf_SPECIAL|OPf_STACKED,
- op_append_elem(OP_LIST,
- $4,
- scalar(newCVREF(
- (OPpENTERSUB_AMPER<<8),
- scalar($2)
- )))); dep();
- TOKEN_GETMAD($1,$$,'o');
- TOKEN_GETMAD($3,$$,'(');
- TOKEN_GETMAD($5,$$,')');
- }
- | DO scalar '(' ')' /* do $subref () */
- { $$ = newUNOP(OP_ENTERSUB, OPf_SPECIAL|OPf_STACKED,
- op_prepend_elem(OP_LIST,
- scalar(newCVREF(0,scalar($2))), (OP*)NULL)); dep();
- TOKEN_GETMAD($1,$$,'o');
- TOKEN_GETMAD($3,$$,'(');
- TOKEN_GETMAD($4,$$,')');
- }
- | DO scalar '(' expr ')' /* do $subref (@args) */
- { $$ = newUNOP(OP_ENTERSUB, OPf_SPECIAL|OPf_STACKED,
- op_prepend_elem(OP_LIST,
- $4,
- scalar(newCVREF(0,scalar($2))))); dep();
- TOKEN_GETMAD($1,$$,'o');
- TOKEN_GETMAD($3,$$,'(');
- TOKEN_GETMAD($5,$$,')');
- }
-
;
term : termbinop