From: Alex Shinn <alexsh...@gmail.com>
Subject: Re: [Chicken-hackers] [PATCH] Adding iset to core and using it for 
Unicode-capable SRFI-14.
Date: Mon, 4 Feb 2013 00:44:27 +0900

> On Mon, Feb 4, 2013 at 12:17 AM, Peter Bex <peter....@xs4all.nl> wrote:
> 
>> On Mon, Feb 04, 2013 at 12:02:44AM +0900, Alex Shinn wrote:
>> > iset manages integer sets.  The srfi-14 proposed
>> > is a thin wrapper around iset, first translating chars to
>> > integers.  We could alternately remove the integer
>> > interface and just use chars for everything.
>>
>> That would require an entirely different implementation, wouldn't it?
>> At least, iset being based on bit-vectors wouldn't be able to
>> store characters as-is.
> 
> 
> Right now we have:
> 
> (define (iset-contains? iset n)
>   (... <lookup> iset n ...))
> (define (char-set-contains? cset ch)
>   (iset-contains? cset (char->integer ch)))
> 
> It's not a big change, but we could remove the wrapper:
> 
> (define (char-set-contains? cset ch)
>   (.. <loookup> cset (char->integer ch) ...))
> 
> Not much actual code is removed, but we do get rid of
> a whole unit and its exported bindings.

That would be nice, indeed.


cheers,
felix

_______________________________________________
Chicken-hackers mailing list
Chicken-hackers@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-hackers

Reply via email to