char-set-filter! does not properly iterate over the charset
authorMichael Gran <spk121@yahoo.com>
Wed, 2 Sep 2009 13:16:35 +0000 (06:16 -0700)
committerMichael Gran <spk121@yahoo.com>
Wed, 2 Sep 2009 13:28:35 +0000 (06:28 -0700)
* libguile/srfi-14.c (scm_char_set_filter_x): iterate over
  codepoints

libguile/srfi-14.c

index 0a283f9..d747973 100644 (file)
@@ -1298,7 +1298,7 @@ SCM_DEFINE (scm_char_set_filter_x, "char-set-filter!", 3, 0, 0,
   for (k = 0; k < p->len; k++)
     for (n = p->ranges[k].lo; n <= p->ranges[k].hi; n++)
       {
-        SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
+        SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (n));
 
         if (scm_is_true (res))
           SCM_CHARSET_SET (base_cs, n);