summaryrefslogtreecommitdiff
path: root/perly.y
diff options
context:
space:
mode:
Diffstat (limited to 'perly.y')
-rw-r--r--perly.y10
1 files changed, 4 insertions, 6 deletions
diff --git a/perly.y b/perly.y
index 7da1be33f1..608f9e0549 100644
--- a/perly.y
+++ b/perly.y
@@ -276,18 +276,16 @@ subrout : SUB startsub subname proto subbody
{ newSUB($2, $3, $4, $5); }
;
-startsub: /* NULL */ /* start a subroutine scope */
- { $$ = start_subparse(); }
+startsub: /* NULL */ /* start a regular subroutine scope */
+ { $$ = start_subparse(0); }
;
startanonsub: /* NULL */ /* start an anonymous subroutine scope */
- { $$ = start_subparse();
- CvANON_on(compcv); }
+ { $$ = start_subparse(CVf_ANON); }
;
startformsub: /* NULL */ /* start a format subroutine scope */
- { $$ = start_subparse();
- CvFORMAT_on(compcv); }
+ { $$ = start_subparse(CVf_FORMAT); }
;
subname : WORD { char *name = SvPVx(((SVOP*)$1)->op_sv, na);