bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

scm_num_eq


From: Roland Orre
Subject: scm_num_eq
Date: Fri, 23 Jan 2004 01:55:18 +0100

Hi,
This code gives the expected result:
 if (SCM_EQ_P(SCM_CDR(handle),SCM_MAKINUM(0)))

but this code doesn't:
  if (scm_num_eq_p(SCM_CDR(handle),SCM_MAKINUM(0)))

as this latter code always gives false back.

I guess it wouldn't matter how the background is, but this
is the case. The key cell is a local variable.

  scm_t_cell key;
  SCM tmp;
  SCM_SETCAR((SCM)&key,SCM_MAKE_STRING_TAG (slen));
  SCM_SETCDR((SCM)&key,(scm_t_bits) str);
  SCM handle=
    scm_hash_fn_create_handle_x (table, (SCM) &key, SCM_MAKINUM(0),
                                 scm_ihash, scm_sloppy_assoc, 0);

        Best regards
        Roland Orre






reply via email to

[Prev in Thread] Current Thread [Next in Thread]