On Mon, Apr 23, 2001 at 11:40:50AM -0700, Larry Wall wrote:
> I do expect that @() and $() will be used for interpolating list and
> scalar expressions into strings, and it is probably the case the $()
> would be a synonym for scalar().  @() would then be a synonym for
> the mythical list() operator.  Which probably, in Perl 6, turns out
> to be equivalent to [...] when used in a scalar context, and a no-op
> in list context.  That is, $() and @() would essentially be typecasts.

Hm, I would expect @() in a scalar context to give the
same result as

  @tmp = @(...); $x = @tmp;

That is, yeild the number of elements in the list.

What would be the benefit of it being the same as [...] ? It would be
one more character.

Graham.

Reply via email to