> "BD" == Brent Dax <[EMAIL PROTECTED]> writes:
BD> Uri Guttman:
BD> # printf "%d hash is $(%foo.string)", $bar ;
BD> #
BD> # no ambiguity and no confusion. how often will you need to
BD> # interpolate a
BD> # hash?
BD> As others have pointed out, %foo{BAR} has to work.
> "BL" == Bart Lateur <[EMAIL PROTECTED]> writes:
BL> On Wed, 6 Mar 2002 17:57:07 -0500, Uri Guttman wrote:
>> how often will you need to interpolate a hash?
BL> A whole hash: quite rarely. A hash item: a LOT. Don't forget that
BL> $foo{BAR} will now become %foo{BAR}
good point. $()
Uri Guttman:
# printf "%d hash is $(%foo.string)", $bar ;
#
# no ambiguity and no confusion. how often will you need to
# interpolate a
# hash?
As others have pointed out, %foo{BAR} has to work. But I have another
question for you: what's wrong with
sprintf '%d hash is %s', $bar,
--- Bart Lateur <[EMAIL PROTECTED]> wrote:
> On Wed, 6 Mar 2002 17:57:07 -0500, Uri Guttman wrote:
>
> >how often will you need to interpolate a hash?
>
> A whole hash: quite rarely. A hash item: a LOT. Don't forget that
> $foo{BAR} will now become %foo{BAR}
Of course, it could also become %s.
On Wed, 6 Mar 2002 17:57:07 -0500, Uri Guttman wrote:
>how often will you need to interpolate a hash?
A whole hash: quite rarely. A hash item: a LOT. Don't forget that
$foo{BAR} will now become %foo{BAR}
--
Bart.
> printf "%d hash is $(%foo.string)", $bar ;
> no ambiguity and no confusion.
This would be nice, if scalar things use '$'. But:
perl5: printf "%d is $foo{bar}", $baz;
perl6: printf "%d is $(%foo{bar})", $baz;
Not so nice.
Dave.
> "BC" == Bernie Cosell <[EMAIL PROTECTED]> writes:
BC> I wonder if the solution is to look at it the other way: that you
BC> have to do something to get interpolation to happen. If we look
BC> at it from the old adage of making the more common things simpler,
BC> at least in my co