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

* Added function scm_error_num_args_subr.

This commit is contained in:
Dirk Herrmann 2001-03-17 11:32:56 +00:00
parent 0c0ffe090a
commit 9f40cd879d
3 changed files with 18 additions and 1 deletions

View file

@ -1,3 +1,7 @@
2001-03-17 Dirk Herrmann <D.Herrmann@tu-bs.de>
* error.[ch] (scm_error_num_args_subr): New function.
2001-03-16 Martin Grabmueller <mgrabmue@cs.tu-berlin.de>
* list.c (scm_list, scm_cons_star, scm_null_p, scm_list_p),

View file

@ -1,4 +1,4 @@
/* Copyright (C) 1995,1996,1997,1998, 2000, 2001 Free Software Foundation, Inc.
/* Copyright (C) 1995,1996,1997,1998,2000,2001 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -252,6 +252,18 @@ scm_wrong_num_args (SCM proc)
SCM_BOOL_F);
}
void
scm_error_num_args_subr (const char *subr)
{
scm_error (scm_args_number_key,
NULL,
"Wrong number of arguments to ~A",
SCM_LIST1 (scm_makfrom0str (subr)),
SCM_BOOL_F);
}
SCM_SYMBOL (scm_arg_type_key, "wrong-type-arg");
void
scm_wrong_type_arg (const char *subr, int pos, SCM bad_value)

View file

@ -73,6 +73,7 @@ extern void scm_out_of_range (const char *subr, SCM bad_value)
extern void scm_out_of_range_pos (const char *subr, SCM bad_value, SCM pos)
SCM_NORETURN;
extern void scm_wrong_num_args (SCM proc) SCM_NORETURN;
extern void scm_error_num_args_subr (const char* subr) SCM_NORETURN;
extern void scm_wrong_type_arg (const char *subr, int pos,
SCM bad_value) SCM_NORETURN;
extern void scm_wrong_type_arg_msg (const char *subr, int pos,