Michael G Schwern <[EMAIL PROTECTED]> writes: > On Mon, Jan 21, 2002 at 03:02:06PM -0500, Tzadik Vanderhoof wrote: >> Why all the fuss? Often, you would *want* to access that lexical after the >> loop terminates, for instance to check how it terminated. > > In most cases you don't want that to happen, usually the life of the > lexical is only the block. If you do want it to live on you can > simply predeclare it. > > my $foo; > if $foo = bar { > ... > } > > which is much simpler than the current setup, where you'll often have > to do this to keep $foo in its proper place. > > do { > if my $foo = bar { > ... > } > }
If, by the time Larry has finished with the apocalypse process you don't have enough tools to write yourself a 'lexif' that does exactly that (and which you can actually define to be 'if' for the remainder of the package file) I will be more than a little surprised. -- Piers "It is a truth universally acknowledged that a language in possession of a rich syntax must be in need of a rewrite." -- Jane Austen?