diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2002-01-05 00:35:19 +0100 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2002-01-04 21:53:30 +0000 |
commit | 466bafcd4432239968dcf0c427d25b79b1833243 (patch) | |
tree | 51c13e27531e66ab16ea2f05c79e8f32064da305 /op.c | |
parent | 824215e2e3b067efbb0104afd616d77cb9526d1a (diff) | |
download | perl-466bafcd4432239968dcf0c427d25b79b1833243.tar.gz |
Bad \[...] prototype checking
Message-ID: <20020104233519.A1850@rafael>
p4raw-id: //depot/perl@14082
Diffstat (limited to 'op.c')
-rw-r--r-- | op.c | 13 |
1 files changed, 10 insertions, 3 deletions
@@ -6787,9 +6787,16 @@ Perl_ck_subr(pTHX_ OP *o) goto again; break; case ']': - if (contextclass) - contextclass = 0; - else + if (contextclass) { + char *p = proto; + char s = *p; + contextclass = 0; + *p = '\0'; + while (*--p != '['); + bad_type(arg, Perl_form("one of %s", p), + gv_ename(namegv), o2); + *proto = s; + } else goto oops; break; case '*': |