comp.lang.ada
 help / color / mirror / Atom feed
From: Victor Porton <porton@narod.ru>
Subject: Re: Array of Unbounded_String vs Indefinite_Vectors(Natural, String)
Date: Sun, 22 Oct 2017 13:52:54 +0300
Date: 2017-10-22T13:52:54+03:00	[thread overview]
Message-ID: <oshta6$u78$1@gioia.aioe.org> (raw)
In-Reply-To: 9588f435-6437-458d-9a3a-468fc96e0865@googlegroups.com

Shark8 wrote:

> On Saturday, October 21, 2017 at 3:48:48 PM UTC-6, Victor Porton wrote:
>> I need to develop an API which return a list of strings.
>> 
>> I have two possible design choices for the result type:
>> 
>> 1. type T is array(Natural range <>) of Unbounded_String;
>> 
>> 2. package V is new Ada.Containers.Indefinite_Vectors(Natural, String);
>> 
>> Which one of the two to choose?
>> 
>> The first has the advantage that it is a regular array not a fancy
>> container. The second one has the advantage that the element type is
>> String not a fancy Unbounded_String.
>> 
>> Please help me to make the choice!
> 
> Personally I like the vector option.

Why?

-- 
Victor Porton - http://portonvictor.org

  reply	other threads:[~2017-10-22 10:52 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-21 21:48 Array of Unbounded_String vs Indefinite_Vectors(Natural, String) Victor Porton
2017-10-22  0:51 ` Shark8
2017-10-22 10:52   ` Victor Porton [this message]
2017-10-23 16:32     ` Shark8
2017-10-23 17:30       ` Jacob Sparre Andersen
2017-11-06  4:42       ` Robert Eachus
2017-10-22 12:30 ` Victor Porton
replies disabled

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