1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-30 15:00:21 +02:00

* procprop.c: #include "libguile/smob.h"; Check applicable smobs.

This commit is contained in:
Mikael Djurfeldt 2000-08-25 04:08:50 +00:00
parent 14fb1c83d6
commit 5540e847f4

View file

@ -52,6 +52,7 @@
#include "libguile/procs.h"
#include "libguile/gsubr.h"
#include "libguile/objects.h"
#include "libguile/smob.h"
#include "libguile/root.h"
#include "libguile/vectors.h"
@ -97,20 +98,27 @@ scm_i_procedure_arity (SCM proc)
a += 2;
r = 1;
break;
#ifdef CCLO
case scm_tc7_cclo:
if (SCM_EQ_P (SCM_CCLO_SUBR (proc), scm_f_gsubr_apply))
case scm_tc7_smob:
{
int type;
if (!SCM_SMOB_DESCRIPTOR (proc).apply)
return SCM_BOOL_F;
type = SCM_SMOB_DESCRIPTOR (proc).gsubr_type;
goto gsubr_type;
case scm_tc7_cclo:
if (SCM_EQ_P (SCM_CCLO_SUBR (proc), scm_f_gsubr_apply))
{
int type = SCM_INUM (SCM_GSUBR_TYPE (proc));
type = SCM_INUM (SCM_GSUBR_TYPE (proc));
gsubr_type:
a += SCM_GSUBR_REQ (type);
o = SCM_GSUBR_OPT (type);
r = SCM_GSUBR_REST (type);
break;
}
proc = SCM_CCLO_SUBR (proc);
a -= 1;
goto loop;
#endif
proc = SCM_CCLO_SUBR (proc);
a -= 1;
goto loop;
}
case scm_tc7_pws:
proc = SCM_PROCEDURE (proc);
goto loop;