summaryrefslogtreecommitdiff
path: root/libguile/array-map.c
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2011-10-24 17:22:47 +0200
committerAndy Wingo <wingo@pobox.com>2011-10-24 17:22:47 +0200
commit62fdadb0a5f10ff34c7e19ac299aa89d950ffc69 (patch)
tree9a8758a238a05db05aa6a9090c30ade2fbe0c514 /libguile/array-map.c
parent8c0e89ac9093aee52620bbdbec07936532f05f3d (diff)
downloadguile-62fdadb0a5f10ff34c7e19ac299aa89d950ffc69.tar.gz
check for pairs with scm_is_pair, not scm_nimp
* libguile/array-map.c (scm_ra_matchp, scm_ramapc): * libguile/dynwind.c (scm_swap_bindings): * libguile/hooks.c (hook_print, scm_c_run_hook, scm_c_run_hookn): * libguile/objprop.c (scm_object_property, scm_set_object_property_x): Use !scm_is_pair as the termination condition, not scm_imp.
Diffstat (limited to 'libguile/array-map.c')
-rw-r--r--libguile/array-map.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libguile/array-map.c b/libguile/array-map.c
index d442bdf4e..395fa11a0 100644
--- a/libguile/array-map.c
+++ b/libguile/array-map.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996,1998,2000,2001,2004,2005, 2006, 2008, 2009, 2010 Free Software Foundation, Inc.
+/* Copyright (C) 1996,1998,2000,2001,2004,2005, 2006, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@@ -99,7 +99,7 @@ scm_ra_matchp (SCM ra0, SCM ras)
else
return 0;
- while (SCM_NIMP (ras))
+ while (scm_is_pair (ras))
{
ra1 = SCM_CAR (ras);
@@ -204,7 +204,7 @@ scm_ramapc (void *cproc_ptr, SCM data, SCM ra0, SCM lra, const char *what)
}
lvra = SCM_EOL;
plvra = &lvra;
- for (z = lra; SCM_NIMP (z); z = SCM_CDR (z))
+ for (z = lra; scm_is_pair (z); z = SCM_CDR (z))
{
ra1 = SCM_CAR (z);
vra1 = scm_i_make_array (1);
@@ -262,7 +262,7 @@ scm_ramapc (void *cproc_ptr, SCM data, SCM ra0, SCM lra, const char *what)
}
lvra = SCM_EOL;
plvra = &lvra;
- for (z = lra; SCM_NIMP (z); z = SCM_CDR (z))
+ for (z = lra; scm_is_pair (z); z = SCM_CDR (z))
{
ra1 = SCM_CAR (z);
vra1 = scm_i_make_array (1);
@@ -295,7 +295,7 @@ scm_ramapc (void *cproc_ptr, SCM data, SCM ra0, SCM lra, const char *what)
{
SCM y = lra;
SCM_I_ARRAY_BASE (vra0) = cind (ra0, vinds);
- for (z = lvra; SCM_NIMP (z); z = SCM_CDR (z), y = SCM_CDR (y))
+ for (z = lvra; scm_is_pair (z); z = SCM_CDR (z), y = SCM_CDR (y))
SCM_I_ARRAY_BASE (SCM_CAR (z)) = cind (SCM_CAR (y), vinds);
if (0 == (SCM_UNBNDP (data) ? cproc(vra0, lvra) : cproc(vra0, data, lvra)))
return 0;