From: Simon Cozens Date: Sun, 10 Dec 2000 00:13:33 +0000 (+0000) Subject: Re: prototype of substr X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3012a639b7f3b366a8c9ef8f4a7141746be0d5de;p=p5sagit%2Fp5-mst-13.2.git Re: prototype of substr Message-ID: <20001210001333.A16221@deep-dark-truthful-mirror.perlhacker.org> Make CORE::substr to be '$$;$$' instead of '$$;$;$'. In other words, make the returned prototypes for any function stop prepending the ';' optionality marker after the first one. If they start getting optional, all the rest are optional. p4raw-id: //depot/perl@8064 --- diff --git a/pp.c b/pp.c index c512db3..f125d56 100644 --- a/pp.c +++ b/pp.c @@ -427,7 +427,7 @@ PP(pp_prototype) found: oa = PL_opargs[i] >> OASHIFT; while (oa) { - if (oa & OA_OPTIONAL) { + if (oa & OA_OPTIONAL && !seen_question) { seen_question = 1; str[n++] = ';'; }