mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-02 21:10:27 +02:00
fix to procedure-arity in previous patch
* libguile/procprop.c (scm_i_procedure_arity): Fix infinite loop.
This commit is contained in:
parent
80be163f81
commit
01e909d90a
1 changed files with 9 additions and 5 deletions
|
@ -72,11 +72,15 @@ scm_i_procedure_arity (SCM proc, int *req, int *opt, int *rest)
|
||||||
{
|
{
|
||||||
if (!SCM_SMOB_APPLICABLE_P (proc))
|
if (!SCM_SMOB_APPLICABLE_P (proc))
|
||||||
return 0;
|
return 0;
|
||||||
if (scm_i_program_arity (SCM_SMOB_DESCRIPTOR (proc).apply_trampoline,
|
if (!scm_i_program_arity (SCM_SMOB_DESCRIPTOR (proc).apply_trampoline,
|
||||||
req, opt, rest))
|
req, opt, rest))
|
||||||
/* The trampoline gets the smob too, which users don't
|
return 0;
|
||||||
see. */
|
|
||||||
*req -= 1;
|
/* The trampoline gets the smob too, which users don't
|
||||||
|
see. */
|
||||||
|
*req -= 1;
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue