[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]

Re: Are STOP and INIT good names? (was Re: [PATCH pod/perlmod.pod 5.005_63] Special Blocks For Less Than Gurus)




Sarathy writes:

   > FWIW, I don't really like READY because of the above. And probably
   > because it only makes sense when read as a verb (at least in my
   > head).

Ah yes, but you must remember that your head is much further removed than
mine from that of the struggling beginner. ;-)


   > I like DONE (as in "done with compilation"), which hasn't been
   > proposed yet, and which conveys the meaning that these things are
   > a finishing point for compilation, not a starting point for
   > execution (which is what INIT is).
   > 
   >     BEGIN
   >     DONE
   >     INIT
   >     END

Hmmmm. To me the obvious order of these is:

        BEGIN
        INIT
        DONE
        END

Remember that most "normal" folks (;-) don't have the sophisticated
understanding of the perlguts that is enjoyed by most in this forum. We
are a simple people who think, not in terms of lexing, compilation, then
execution, but in terms of a single flow of control through the program
source.

So the names of these blocks are interpreted relative to that flow of
control, not the mysterious phases of the interpreter. In fact, I
suspect that most people just mentally tack the word "PROGRAM" after the
block name:

        BEGIN PROGRAM
        INIT PROGRAM
        END PROGRAM

If that's the case, I still prefer:

        READY PROGRAM
to:
        DONE PROGRAM

Although, I confess that, in this context, READY is not perfect either.
Ah well, back to the thesaurus.

Damian


Follow-Ups from:
Gurusamy Sarathy <gsar@ActiveState.com>
Ilya Zakharevich <ilya@math.ohio-state.edu>

[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]