From: Javi <fjvera@gmail.com>
Subject: access assignation. Aliasing problems?
Date: Fri, 1 Feb 2008 02:01:08 -0800 (PST)
Date: 2008-02-01T02:01:08-08:00 [thread overview]
Message-ID: <6766a791-abf3-4571-b5f7-98751a948f13@j78g2000hsd.googlegroups.com> (raw)
Hi again, I have some problem between access assignations. "List" has
in its definition a private access to ListNode (First, Last). Why
can't I do the assignation: L.List := L.Last ? it does produce an
"accessibilty error check". If both values are null, I can not either
do the assignation.
-----------
...
procedure putItem (L : in out List; It : in ItemList) is
begin
if L.Last = null then
L.Last := new ListNode'(Item => It, next => null);
print(L.Last.Item); --DBG this prints OK, the Item was
properly assigned
L.First := L.Last; -- this fails, L.First and L.Last are both
the same type access ListNode
...
----------
I'm very sorry because of bothering you with this simple questions,
thanks again.
next reply other threads:[~2008-02-01 10:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-01 10:01 Javi [this message]
2008-02-01 14:02 ` access assignation. Aliasing problems? Robert A Duff
2008-02-01 18:24 ` Jeffrey R. Carter
2008-02-02 10:37 ` Stephen Leake
2008-02-02 21:02 ` Javi
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox