comp.lang.ada
 help / color / mirror / Atom feed
From: Martin Trenkmann <martin.trenkmann@posteo.de>
Subject: Re: Implementing character sets for Wide_Character
Date: Fri, 06 Mar 2015 22:02:41 +0100
Date: 2015-03-06T22:02:41+01:00	[thread overview]
Message-ID: <mdd4lh$oq1$1@news.albasani.net> (raw)
In-Reply-To: <87385i9emd.fsf@theworld.com>

>> I need to implement a containment check for Wide_Character in a wide
>> character set. I have two approaches in mind.
> 
> If you really care about speed, then implement both and measure the
> speed.  It's not clear that the bit map will be faster -- using more
> memory harms cache behavior.

Yes that's true.

> Also take a look at package Ada.Strings.Wide_Maps.
> It contains type Wide_Character_Set, represented as a sorted
> sequence of ranges.  Measure that one, too.

Don't know why I overlooked that package. I don't intend to reinvent the wheel - thanks for the hint.

> Why Wide_Character rather than Wide_Wide_Character?

Because my pretty old character set I have to deal with assigns Japanese characters to 16-bit values.

- Martin

  reply	other threads:[~2015-03-06 21:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-06 18:01 Implementing character sets for Wide_Character Martin Trenkmann
2015-03-06 18:15 ` Bob Duff
2015-03-06 21:02   ` Martin Trenkmann [this message]
2015-03-06 18:18 ` G.B.
2015-03-06 21:06   ` Martin Trenkmann
2015-03-06 22:21     ` Bob Duff
2015-03-06 19:24 ` Dmitry A. Kazakov
2015-03-06 21:48 ` Jeffrey Carter
replies disabled

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