From: "Jeffrey R. Carter" <spam.jrcarter.not@spam.not.acm.org>
Subject: Re: Ada 2005,Doubly_Linked_List with Controlled parameter
Date: Mon, 4 Apr 2016 23:20:12 -0700
Date: 2016-04-04T23:20:12-07:00 [thread overview]
Message-ID: <ndvl8o$bji$1@dont-email.me> (raw)
In-Reply-To: <1083384c-e798-49a0-903a-718dea4ab131@googlegroups.com>
On 04/04/2016 08:00 PM, George J wrote:
>
> Ok,thanks,and if I correctly understood,if I have record with
multiple parameters, i must do it like
> ---------------------------------
> type Info_Record is
> Name:Unbounded_String;--ok
> Surname:Unbounded_String;
> Age:Natural;
> end Info_Record;
> --------------------------------
> Am I right?
> And are they normally will be deleted from memory with finalization
of Doubly_Connected_List?
Yes. Your example, with only a single string, appeared to be an attempt
to reinvent Unbounded_String, but if you need a type with multiple such
values, this is a way to do it.
"The type Unbounded_String needs finalization (see 7.6)." and "No
storage associated with an Unbounded_String object shall be lost upon
assignment or scope exit." ARM A.4.5
(http://www.adaic.org/resources/add_content/standards/05rm/html/RM-A-4-5.html).
But I see you've discovered that already.
(Some on here dislike Unbounded_String, but if it serves your purposes
you should ignore them and use it. I worked on a large, soft-real-time
system that used Unbounded_String extensively without problem, so such
people's concerns seem to be unfounded.)
--
Jeff Carter
"Hold your temper. Count ten.... Now let 'er go.
You got a good aim."
Never Give a Sucker an Even Break
105
next prev parent reply other threads:[~2016-04-05 6:20 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-05 2:03 Ada 2005,Doubly_Linked_List with Controlled parameter George J
2016-04-05 2:27 ` Jeffrey R. Carter
2016-04-05 3:00 ` George J
2016-04-05 4:13 ` George J
2016-04-05 6:20 ` Jeffrey R. Carter [this message]
2016-04-05 6:31 ` George J
2016-04-05 7:58 ` Dmitry A. Kazakov
2016-04-05 8:09 ` George J
2016-04-05 8:35 ` George J
2016-04-05 8:50 ` Dmitry A. Kazakov
2016-04-05 8:57 ` George J
2016-04-05 16:22 ` Jeffrey R. Carter
2016-04-06 1:14 ` George J
2016-04-05 3:25 ` George J
2016-04-05 5:24 ` Jeffrey R. Carter
2016-04-05 6:30 ` George J
2016-04-06 20:29 ` Randy Brukardt
2016-04-06 21:04 ` Jeffrey R. Carter
2016-04-07 1:28 ` George J
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox