comp.lang.ada
 help / color / mirror / Atom feed
From: "G.B." <bauhaus@notmyhomepage.invalid>
Subject: Re: Multiple iterators for a type
Date: Sat, 26 May 2018 09:14:57 +0200
Date: 2018-05-26T09:14:57+02:00	[thread overview]
Message-ID: <peb1hi$b5a$1@dont-email.me> (raw)
In-Reply-To: <574749990.548999719.627915.laguest-archeia.com@nntp.aioe.org>

On 26.05.18 05:57, Luke A. Guest wrote:
> Stephen Leake <> wrote:
> 
>> An "iterator" can be anything you want it to be. As Randy pointed out,
>> there can be only one that gets special treatment from the compiler, but
>> you did not mention that as a requirement.
>>
> 
> I’m attempting to implement a Unicode string using UTF-8, so I want the
> basic iterator over octets, then the next will iterate over the octets and
> generate code points, then another will be graphème clusters.

Would layering work where each layer uses
   Has_Element
   Next

This should then work with streams, too, that is,
with open ended arrays read from some source.

      parent reply	other threads:[~2018-05-26  7:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-25 16:49 Multiple iterators for a type Lucretia
2018-05-25 19:50 ` Jacob Sparre Andersen
2018-05-25 21:50   ` Randy Brukardt
2018-05-26  3:13 ` Stephen Leake
2018-05-26  3:57   ` Luke A. Guest
2018-05-26  4:44     ` Jere
2018-05-26  6:59     ` Dmitry A. Kazakov
2018-05-26 12:33       ` Dan'l Miller
2018-05-26 13:03       ` Lucretia
2018-05-26 13:52         ` Dmitry A. Kazakov
2018-05-26 14:22           ` Dan'l Miller
2018-05-26  7:14     ` G.B. [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