Conditional compilation

Peter Hansen peter at engcorp.com
Mon May 13 19:52:05 EDT 2002


Garth T Kidd wrote:
> 
> One thing I love in UserTalk (of Frontier, Manilla and Radio UserLand
> fame) is the 'bundle' keyword that simply provides another variable
> scope and bundles up a few lines of code.
> 
> Compare::
> 
>     # do this
> 
>     ... code to do this
> 
>     # do that
> 
>     ... code to do that
> 
> With::
> 
>     bundle # do this
>         ... code to do this
> 
>     bundle # do that
>         ... code to do that

I fail to see any advantage to that structure.  Wouldn't this be
even better in any case? :

   subroutineCallToDoThis()
   subroutineCallToDoThat()

It's more concise, self-documenting, more modular, maintainable,
more testable, and so forth....

Just what value does "bundle" provide?  Your example doesn't show it.

-Peter



More information about the Python-list mailing list