Re: predicate->char-set considered harmful Brad Lucier (18 Dec 2000 16:01 UTC)
Re: predicate->char-set considered harmful shivers@xxxxxx (18 Dec 2000 16:12 UTC)

Re: predicate->char-set considered harmful Brad Lucier 18 Dec 2000 16:01 UTC

>
>    From: xxxxxx@math.purdue.edu
>    Date: Sun, 17 Dec 2000 22:44:02 -0500 (EST)
>
>    What about predicate->char-set on large (Unicode or larger) character sets?
>    I'd certainly not want to call a function 65536 times (or 2^32 times) just
>    to construct a char-set. And a user may not know that a Scheme
>    implementation has two-byte or four-byte characters. (How many people know
>    that Gambit has 2-byte chars by default?) I just don't see how it's really
>    helpful to have this function, and I think it should be eliminated.
>
> Valid concerns, but it can't be helped. People frequently describe sets of
> things by predicate; you need a way to convert that into a true set.

There are enough ways to build char-sets that I don't think it
is *essential* that one has such an expensive operation.  For example,
I think it would be better to just construct a list of chars, and use
list->char-set.

I hope you don't try to define predicate->bitset in a later SRFI ;-).

Brad