At 09:28 AM 8/8/00 +0100, Piers Cawley wrote:
>Peter Scott <[EMAIL PROTECTED]> writes:
>
> > At 12:07 AM 8/8/00 +0200, Bart Lateur wrote:
> > >On Mon, 07 Aug 2000 10:56:40 -0700, Peter Scott wrote:
> > >
> > > >I meant that BEGIN, END, and INIT aren't declared as subs at present but
> > > >named blocks.  I was surprised to discover that they're put in the 
> symbol
> > > >table anyway though.
> > >
> > >Check the docs again. [snip]
> > >     Four special subroutines act as package constructors and
> > >     destructors. These are the `BEGIN', `CHECK', `INIT', and `END'
> > >     routines. The `sub' is optional for these routines.
> >
> > Drat.  I propose making it non-optional for 
> P6.  ETOOMANYSPECIALCASES.  Any
> > objections?
>
>But what happens if you want multiple BEGIN blocks?

Same as now:

$ perl -le 'sub BEGIN{print "one"} sub BEGIN{print "two"}'
one
two

It's a bit of a white lie to suggest that they're just plain ol' 
subroutines, but at least we're getting closer to the truth.

--
Peter Scott
Pacific Systems Design Technologies

Reply via email to