[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]
Are STOP and INIT good names? (was Re: [PATCH pod/perlmod.pod 5.005_63] Special Blocks For Less Than Gurus)
On Sat, Jan 22, 2000 at 08:15:15PM -0800, Gurusamy Sarathy wrote:
> >PPS Why is STOP called STOP?
>
> STOP is called that because it is where the compilation phase
> terminates. In the context of the compiler, STOP blocks are the
> precursor to a state of suspended animation in the life of a Perl
> program.
Wow, that's less than intutitive. I guess if you're deeply
knowledgable about the internals or really into XS it makes
sense... but I'm neither and I'd suspect most other people aren't.
Why does this remind me of an old episode of "Alice"? They label the
double doors between the kitchen and the dining room "IN" and "OUT".
Some people going from the kitchen to the dining room use the "OUT"
door since they're going -out- of the kitchen. Some use the "IN" door
since they're going -into- the dining room. Of course, comedy ensues
and somebody winds up getting a pie in the face.
Anyhow (I guess you had to watch the show) point is that it makes just
as much sense to name it 'STOP' as it does 'START'. Is it where
compilation stops or is it where runtime starts?
Additionally, 'STOP' could be associated with any step.
'BEGIN' is obvious. Its when the program begins. 'END' is also
obvious. Neither name needs explaining since the assumption is that
you're talking about the program as a whole, not individual phases of
it. 'STOP' and 'INIT' don't have this nature. My initial reaction to
'STOP' was that it was when the program stopped, which made me wonder
how it was different than 'END'.
Of course, I can't think of better names. I guess I'm just bitching.
Maybe you could give me some typical examples of their uses (beyond
the light treatment in perlmod) and I'll ponder.
PS I hope I'm not dreging up something that's already been settled. I
didn't notice any discussion in the archives.
--
Michael G Schwern schwern@pobox.com
http://www.pobox.com/~schwern
/(?:(?:(1)[.-]?)?\(?(\d{3})\)?[.-]?)?(\d{3})[.-]?(\d{4})(x\d+)?/i
- Follow-Ups from:
-
Gurusamy Sarathy <gsar@ActiveState.com>
- References to:
-
Michael G Schwern <schwern@pobox.com>
Gurusamy Sarathy <gsar@ActiveState.com>
[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]