From: Jeffrey Carter <spam.jrcarter.not@spam.not.acm.org>
Subject: Re: Help with type definition
Date: Fri, 16 May 2014 10:57:29 -0700
Date: 2014-05-16T10:57:29-07:00 [thread overview]
Message-ID: <ll5jia$ak1$2@dont-email.me> (raw)
In-Reply-To: <8beec1c1-9ca2-44fc-9d7e-0cd0aa772dcc@googlegroups.com>
On 05/16/2014 12:37 AM, hanslad@gmail.com wrote:
>
> type String_Type_Implementation(Count : Natural) is record
> Data : String(1 .. Count) := "";
> end record;
>
> type String_Type_Implementation_Ptr is access String_Type_Implementation;
>
> type String_Type is new Ada.Finalization.Controlled with record
> Length : Integer;
> Implementation : String_Type_Implementation_Ptr;
> end record;
String_Type is not suitable for sending over the network, so why not simply use
Ada.Strings.Unbounded.Unbounded_String for the string value in type Node? You're
going to have to construct the sequence of bytes to go over the network in
either case.
A consistent coding and naming style, and a lot fewer occurrences of the
sequence [t|T]ype would make your code easier to read.
--
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:[~2014-05-16 17:57 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-16 7:37 Help with type definition hanslad
2014-05-16 7:54 ` Dmitry A. Kazakov
2014-05-16 10:03 ` G.B.
2014-05-16 11:26 ` Jacob Sparre Andersen
2014-05-16 15:38 ` Shark8
2014-05-16 15:50 ` Simon Wright
2014-05-16 16:30 ` Shark8
2014-05-16 11:29 ` Jacob Sparre Andersen
2014-05-16 12:29 ` G.B.
2014-05-16 17:57 ` Jeffrey Carter [this message]
2014-05-21 20:45 ` hanslad
2014-06-27 22:05 ` hanslad
2014-06-28 7:26 ` Shark8
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox