comp.lang.ada
 help / color / mirror / Atom feed
From: Martin Krischik <krischik@users.sourceforge.net>
Subject: Re: warning: cannot return a local value by reference
Date: Thu, 03 Jun 2004 12:37:38 +0200
Date: 2004-06-03T12:37:38+02:00	[thread overview]
Message-ID: <2798452.09WdW2qvTy@linux1.krischik.com> (raw)
In-Reply-To: 40bef751$0$13933$636a15ce@news.free.fr

k_leau wrote:

> I think that's because Connection_type is a limited type and there was an
> error message telling me "completion of non limited type cannot be
> limited"...so I put limited in the public view and the error
> disappeared... I am just an Ada newbie...and I am far for understanding
> all the subtleties of the language yet.

Well that is in fact correct. If Connection_type is limited the record need
to be limited as well.

But than it should have been:

ᅵᅵᅵᅵᅵtypeᅵitem_dbmᅵis limitedᅵrecord
ᅵᅵᅵᅵᅵᅵᅵᅵᅵit:ᅵitem;
ᅵᅵᅵᅵᅵᅵᅵᅵᅵconnection:ᅵconnection_type;
ᅵᅵᅵᅵᅵendᅵrecord;

as well. Otherwise I would expect that the record is not limited when used
privatly. Privat use is allowed for the package and all it's child
packages.

One of the language lawers might explain why not.

With Regards

Martin
-- 
mailto://krischik@users.sourceforge.net
http://www.ada.krischik.com




      reply	other threads:[~2004-06-03 10:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-02 22:11 warning: cannot return a local value by reference k_leau
2004-06-02 22:36 ` Georg Bauhaus
2004-06-02 22:49   ` k_leau
2004-06-03  8:23 ` Martin Krischik
2004-06-03 10:02   ` k_leau
2004-06-03 10:37     ` Martin Krischik [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox