HaloO,

John M. Dlugosz wrote:
TSa Thomas.Sandlass-at-vts-systems.de |Perl 6| wrote:
Is it generally foreseen that an object knows about the containers
it is stored in?
Yes. But it is not generally the case that this is the same container as the caller is holding. Detailed specifications of the meaning of 'read-only', 'rw', 'copy', and 'ref' and the binding semantics thereof need to address this, and address the concerns of efficient implementations.

I meant the general 1:n relation of value to containers not the
relation of outer and inner containers in sub calls. I think that
back refs from the value to all containers is cumbersome and of
little practical value if the semantics of the language don't
require it. E.g. if the deletion of values were possible then all
containers holding the value need to be nulled. The back refs
need to be updated when a container receives a new value. It has
to detach from the former value and attach to the new one.

So again the question: are back refs from the value to the containers
required to implement Perl 6? I guess not.


Regards, TSa.
--

"The unavoidable price of reliability is simplicity" -- C.A.R. Hoare
"Simplicity does not precede complexity, but follows it." -- A.J. Perlis
1 + 2 + 3 + 4 + ... = -1/12  -- Srinivasa Ramanujan

Reply via email to