On Sat, Apr 23, 2005 at 09:50:26PM +0200, Juerd wrote: > Autrijus Tang skribis 2005-04-24 3:47 (+0800): > > $x := @a[0]; # vivified or not? > > Vivified, because you're taking a reference (not at language level) and > you can't have a reference (at internal level) pointing to something > that doesn't exist. At language level, you can, but only symbolically.
Okay. Implemented as r2260, with full call-by-value semantics as
defined by Larry's previous post. `bindings.t` passes under either
semantics, as expected.
Please sanity-check the following:
pugs> my ($x, @a); $x := @a[-1]; $x = 3; @a
*** Error: Modification of non-creatable array value attempted
pugs> my ($x, @a); $x := @a[0]<x>[1]<y>; $x = 3; @a[0]<x>[1]<y>
3
pugs> my ($x, @a); $x := [EMAIL PROTECTED]; $x = 3
*** Error: Can't modify constant item
Thanks,
/Autrijus/
pgpgpMzuYZEer.pgp
Description: PGP signature
