Austin Hastings <[EMAIL PROTECTED]> writes:
> Let it be.
>
> Not a flame, but a suggestion:
>
> let $pi be constant;
Personally, I'd rather save let for:
(let ($x,$y,$z,...) = (1,2,3,...) in { ... })
which would be equivilant to:
((sub {my ($x,$y,$z,...) = @_; ... })(1,2,3,...))
Many functional languages use let to mean something similar.
On that note... will there be any provision for formal arguments to
anonymous subs?
If I understand the brief mentions of subroutine signatures, we will
be able to use syntax like:
sub foo (@array, $scalar, %hash) { ... } ;
Will we also be able to do:
$foo = sub (@array, $scalar, %hash) { ... } ;
to get a reference to an anonymous sub with the same signature?
If so, then
$foo = (let (...) = (...) in {...});
could be equivalent to:
$foo = ((sub (...) {...})(...));
>
> That any better?
>
> =Austin
>
> --- Dan Schmidt <[EMAIL PROTECTED]> wrote:
> > Peter Scott <[EMAIL PROTECTED]> writes:
> >
> > | I've been reading "is" as a declarative imperative, something which
> > | declares a property of something you are creating. Here it's being
> > | used to modify the properties of something that already exists, and
> > | it reads funny to me. Many properties that one can set at
> > | declaration time are compile time only, yet this usage might
> > suggest
> > | to many people that they can be changed at run time. If you see
> > | what I mean.
> >
> > Clearly we need 'becomes' and 'gets' for mutable properties, in
> > addition to 'is' and 'has' for constant ones.
> >
> > --
> > http://www.dfan.org
> >
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - buy the things you want at great prices
> http://auctions.yahoo.com/