1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-24 12:20:20 +02:00

* gh.h: Don't take the address of a SCM value.

* sort.c: Don't take the address of SCM_CAR, use SCM_CARLOC instead.
This commit is contained in:
Dirk Herrmann 2000-06-05 12:09:35 +00:00
parent 9a09deb1c3
commit 4b479d9818
3 changed files with 18 additions and 9 deletions

View file

@ -485,7 +485,7 @@ SCM_DEFINE (scm_sorted_p, "sorted?", 2, 0, 0,
j = len - 1;
while (j > 0)
{
if ((*cmp) (less, &SCM_CAR(rest), &item))
if ((*cmp) (less, SCM_CARLOC(rest), &item))
return SCM_BOOL_F;
else
{
@ -555,7 +555,7 @@ SCM_DEFINE (scm_merge, "merge", 3, 0, 0,
{
SCM_VALIDATE_NONEMPTYLIST_COPYLEN (1,alist,alen);
SCM_VALIDATE_NONEMPTYLIST_COPYLEN (2,blist,blen);
if ((*cmp) (less, &SCM_CAR (blist), &SCM_CAR (alist)))
if ((*cmp) (less, SCM_CARLOC (blist), SCM_CARLOC (alist)))
{
build = scm_cons (SCM_CAR (blist), SCM_EOL);
blist = SCM_CDR (blist);
@ -570,7 +570,7 @@ SCM_DEFINE (scm_merge, "merge", 3, 0, 0,
last = build;
while ((alen > 0) && (blen > 0))
{
if ((*cmp) (less, &SCM_CAR (blist), &SCM_CAR (alist)))
if ((*cmp) (less, SCM_CARLOC (blist), SCM_CARLOC (alist)))
{
SCM_SETCDR (last, scm_cons (SCM_CAR (blist), SCM_EOL));
blist = SCM_CDR (blist);
@ -607,7 +607,7 @@ scm_merge_list_x (SCM alist, SCM blist,
return alist;
else
{
if ((*cmp) (less, &SCM_CAR (blist), &SCM_CAR (alist)))
if ((*cmp) (less, SCM_CARLOC (blist), SCM_CARLOC (alist)))
{
build = blist;
blist = SCM_CDR (blist);
@ -622,7 +622,7 @@ scm_merge_list_x (SCM alist, SCM blist,
last = build;
while ((alen > 0) && (blen > 0))
{
if ((*cmp) (less, &SCM_CAR (blist), &SCM_CAR (alist)))
if ((*cmp) (less, SCM_CARLOC (blist), SCM_CARLOC (alist)))
{
SCM_SETCDR (last, blist);
blist = SCM_CDR (blist);
@ -698,8 +698,8 @@ scm_merge_list_step (SCM * seq,
SCM_SETCDR (rest, SCM_EOL);
if ((*cmp) (less, &y, &x))
{
SCM_CAR (p) = y;
SCM_CAR (rest) = x;
SCM_SETCAR (p, y);
SCM_SETCAR (rest, x);
}
return p;
}