diff options
author | Greg J. Badros <gjb@cs.washington.edu> | 2000-03-02 20:54:43 +0000 |
---|---|---|
committer | Greg J. Badros <gjb@cs.washington.edu> | 2000-03-02 20:54:43 +0000 |
commit | 7866a09b5b355ea277d2dd780b24e98f647329d4 (patch) | |
tree | 475d3833314d66222ba9773505eec1f0af7d3b01 | |
parent | e510ed373f315ca26f17be1ebe963c5c226a158e (diff) | |
download | guile-7866a09b5b355ea277d2dd780b24e98f647329d4.tar.gz |
* list.c: Moved append docs to append! Thanks Dirk Hermann. Also,
added append docs from R4RS.
* strings.c: Docstring typo fix, + eliminate unneeded IMP tests.
Thanks Dirk Hermann!
* chars.h: Provide SCM_CHARP, SCM_CHAR, SCM_MAKE_CHAR and
deprecate SCM_ICHRP, SCM_ICHR, SCM_MAKICHR. Thanks Dirk Hermann!
* *.h, *.c: Use SCM_CHARP, SCM_CHAR, SCM_MAKE_CHAR throughout.
Drop use of SCM_P for function prototypes... assume an ANSI C
compiler. Thanks Dirk Hermann!
79 files changed, 942 insertions, 941 deletions
diff --git a/libguile/__scm.h b/libguile/__scm.h index 7e2f8f623..960b92819 100644 --- a/libguile/__scm.h +++ b/libguile/__scm.h @@ -122,18 +122,6 @@ typedef unsigned long long ulong_long; #endif /* HAVE_LONG_LONGS */ -/* Write prototype declarations like this: - int foo SCM_P ((int a, int b)); - At definitions, use K&R style declarations, but make sure there's a - declarative prototype (as above) in scope. This will give you - argument type checking, when available, and be harmless otherwise. */ -#ifdef __STDC__ -# define SCM_P(x) x -#else -# define SCM_P(x) () -#endif - - /* Define * diff --git a/libguile/alist.h b/libguile/alist.h index 058fe512c..f04610a7a 100644 --- a/libguile/alist.h +++ b/libguile/alist.h @@ -48,22 +48,22 @@ -extern SCM scm_acons SCM_P ((SCM w, SCM x, SCM y)); -extern SCM scm_sloppy_assq SCM_P ((SCM x, SCM alist)); -extern SCM scm_sloppy_assv SCM_P ((SCM x, SCM alist)); -extern SCM scm_sloppy_assoc SCM_P ((SCM x, SCM alist)); -extern SCM scm_assq SCM_P ((SCM x, SCM alist)); -extern SCM scm_assv SCM_P ((SCM x, SCM alist)); -extern SCM scm_assoc SCM_P ((SCM x, SCM alist)); -extern SCM scm_assq_ref SCM_P ((SCM alist, SCM key)); -extern SCM scm_assv_ref SCM_P ((SCM alist, SCM key)); -extern SCM scm_assoc_ref SCM_P ((SCM alist, SCM key)); -extern SCM scm_assq_set_x SCM_P ((SCM alist, SCM key, SCM val)); -extern SCM scm_assv_set_x SCM_P ((SCM alist, SCM key, SCM val)); -extern SCM scm_assoc_set_x SCM_P ((SCM alist, SCM key, SCM val)); -extern SCM scm_assq_remove_x SCM_P ((SCM alist, SCM key)); -extern SCM scm_assv_remove_x SCM_P ((SCM alist, SCM key)); -extern SCM scm_assoc_remove_x SCM_P ((SCM alist, SCM key)); -extern void scm_init_alist SCM_P ((void)); +extern SCM scm_acons (SCM w, SCM x, SCM y); +extern SCM scm_sloppy_assq (SCM x, SCM alist); +extern SCM scm_sloppy_assv (SCM x, SCM alist); +extern SCM scm_sloppy_assoc (SCM x, SCM alist); +extern SCM scm_assq (SCM x, SCM alist); +extern SCM scm_assv (SCM x, SCM alist); +extern SCM scm_assoc (SCM x, SCM alist); +extern SCM scm_assq_ref (SCM alist, SCM key); +extern SCM scm_assv_ref (SCM alist, SCM key); +extern SCM scm_assoc_ref (SCM alist, SCM key); +extern SCM scm_assq_set_x (SCM alist, SCM key, SCM val); +extern SCM scm_assv_set_x (SCM alist, SCM key, SCM val); +extern SCM scm_assoc_set_x (SCM alist, SCM key, SCM val); +extern SCM scm_assq_remove_x (SCM alist, SCM key); +extern SCM scm_assv_remove_x (SCM alist, SCM key); +extern SCM scm_assoc_remove_x (SCM alist, SCM key); +extern void scm_init_alist (void); #endif /* ALISTH */ diff --git a/libguile/arbiters.h b/libguile/arbiters.h index 19359791d..d7a0ccaa5 100644 --- a/libguile/arbiters.h +++ b/libguile/arbiters.h @@ -48,9 +48,9 @@ -extern SCM scm_make_arbiter SCM_P ((SCM name)); -extern SCM scm_try_arbiter SCM_P ((SCM arb)); -extern SCM scm_release_arbiter SCM_P ((SCM arb)); -extern void scm_init_arbiters SCM_P ((void)); +extern SCM scm_make_arbiter (SCM name); +extern SCM scm_try_arbiter (SCM arb); +extern SCM scm_release_arbiter (SCM arb); +extern void scm_init_arbiters (void); #endif /* ARBITERSH */ diff --git a/libguile/async.h b/libguile/async.h index d44023165..ff67c7d23 100644 --- a/libguile/async.h +++ b/libguile/async.h @@ -66,19 +66,19 @@ extern unsigned int scm_mask_ints; extern SCM scm_gc_async; -extern int scm_asyncs_pending SCM_P ((void)); -extern void scm_async_click SCM_P ((void)); -extern void scm_switch SCM_P ((void)); -extern SCM scm_async SCM_P ((SCM thunk)); -extern SCM scm_system_async SCM_P ((SCM thunk)); -extern SCM scm_async_mark SCM_P ((SCM a)); -extern SCM scm_system_async_mark SCM_P ((SCM a)); -extern SCM scm_run_asyncs SCM_P ((SCM list_of_a)); -extern SCM scm_noop SCM_P ((SCM args)); -extern SCM scm_set_tick_rate SCM_P ((SCM n)); -extern SCM scm_set_switch_rate SCM_P ((SCM n)); -extern SCM scm_unmask_signals SCM_P ((void)); -extern SCM scm_mask_signals SCM_P ((void)); -extern void scm_init_async SCM_P ((void)); +extern int scm_asyncs_pending (void); +extern void scm_async_click (void); +extern void scm_switch (void); +extern SCM scm_async (SCM thunk); +extern SCM scm_system_async (SCM thunk); +extern SCM scm_async_mark (SCM a); +extern SCM scm_system_async_mark (SCM a); +extern SCM scm_run_asyncs (SCM list_of_a); +extern SCM scm_noop (SCM args); +extern SCM scm_set_tick_rate (SCM n); +extern SCM scm_set_switch_rate (SCM n); +extern SCM scm_unmask_signals (void); +extern SCM scm_mask_signals (void); +extern void scm_init_async (void); #endif /* ASYNCH */ diff --git a/libguile/backtrace.h b/libguile/backtrace.h index 7cdd257a0..af9f137ee 100644 --- a/libguile/backtrace.h +++ b/libguile/backtrace.h @@ -51,15 +51,15 @@ extern SCM scm_the_last_stack_fluid; -void scm_display_error_message SCM_P ((SCM message, SCM args, SCM port)); -SCM scm_display_error SCM_P ((SCM stack, SCM port, SCM subr, SCM message, SCM args, SCM rest)); +void scm_display_error_message (SCM message, SCM args, SCM port); +SCM scm_display_error (SCM stack, SCM port, SCM subr, SCM message, SCM args, SCM rest); SCM scm_display_application (SCM frame, SCM port, SCM indent); -SCM scm_display_backtrace SCM_P ((SCM stack, SCM port, SCM first, SCM depth)); -SCM scm_backtrace SCM_P ((void)); +SCM scm_display_backtrace (SCM stack, SCM port, SCM first, SCM depth); +SCM scm_backtrace (void); #ifdef GUILE_DEBUG SCM scm_set_print_params_x (SCM params); #endif -void scm_init_backtrace SCM_P ((void)); +void scm_init_backtrace (void); #endif /* BACKTRACEH */ diff --git a/libguile/boolean.h b/libguile/boolean.h index 59c7df218..b7a575a4a 100644 --- a/libguile/boolean.h +++ b/libguile/boolean.h @@ -68,8 +68,8 @@ -extern SCM scm_not SCM_P ((SCM x)); -extern SCM scm_boolean_p SCM_P ((SCM obj)); -extern void scm_init_boolean SCM_P ((void)); +extern SCM scm_not (SCM x); +extern SCM scm_boolean_p (SCM obj); +extern void scm_init_boolean (void); #endif /* BOOLEANH */ diff --git a/libguile/chars.c b/libguile/chars.c index f93f8d785..a83fcccec 100644 --- a/libguile/chars.c +++ b/libguile/chars.c @@ -57,7 +57,7 @@ SCM_DEFINE (scm_char_p, "char?", 1, 0, 0, "Return #t iff X is a character, else #f.") #define FUNC_NAME s_scm_char_p { - return SCM_BOOL(SCM_ICHRP(x)); + return SCM_BOOL(SCM_CHARP(x)); } #undef FUNC_NAME @@ -66,9 +66,9 @@ SCM_DEFINE1 (scm_char_eq_p, "char=?", scm_tc7_rpsubr, "Return #t iff X is the same character as Y, else #f.") #define FUNC_NAME s_scm_char_eq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(SCM_ICHR(x) == SCM_ICHR(y)); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(SCM_CHAR(x) == SCM_CHAR(y)); } #undef FUNC_NAME @@ -78,9 +78,9 @@ SCM_DEFINE1 (scm_char_less_p, "char<?", scm_tc7_rpsubr, "Return #t iff X is less than Y in the Ascii sequence, else #f.") #define FUNC_NAME s_scm_char_less_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(SCM_ICHR(x) < SCM_ICHR(y)); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(SCM_CHAR(x) < SCM_CHAR(y)); } #undef FUNC_NAME @@ -89,9 +89,9 @@ SCM_DEFINE1 (scm_char_leq_p, "char<=?", scm_tc7_rpsubr, "Return #t iff X is less than or equal to Y in the Ascii sequence, else #f.") #define FUNC_NAME s_scm_char_leq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(SCM_ICHR(x) <= SCM_ICHR(y)); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(SCM_CHAR(x) <= SCM_CHAR(y)); } #undef FUNC_NAME @@ -100,9 +100,9 @@ SCM_DEFINE1 (scm_char_gr_p, "char>?", scm_tc7_rpsubr, "Return #t iff X is greater than Y in the Ascii sequence, else #f.") #define FUNC_NAME s_scm_char_gr_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(SCM_ICHR(x) > SCM_ICHR(y)); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(SCM_CHAR(x) > SCM_CHAR(y)); } #undef FUNC_NAME @@ -111,9 +111,9 @@ SCM_DEFINE1 (scm_char_geq_p, "char>=?", scm_tc7_rpsubr, "Return #t iff X is greater than or equal to Y in the Ascii sequence, else #f.") #define FUNC_NAME s_scm_char_geq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(SCM_ICHR(x) >= SCM_ICHR(y)); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(SCM_CHAR(x) >= SCM_CHAR(y)); } #undef FUNC_NAME @@ -122,9 +122,9 @@ SCM_DEFINE1 (scm_char_ci_eq_p, "char-ci=?", scm_tc7_rpsubr, "Return #t iff X is the same character as Y ignoring case, else #f.") #define FUNC_NAME s_scm_char_ci_eq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(scm_upcase(SCM_ICHR(x))==scm_upcase(SCM_ICHR(y))); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(scm_upcase(SCM_CHAR(x))==scm_upcase(SCM_CHAR(y))); } #undef FUNC_NAME @@ -133,9 +133,9 @@ SCM_DEFINE1 (scm_char_ci_less_p, "char-ci<?", scm_tc7_rpsubr, "Return #t iff X is less than Y in the Ascii sequence ignoring case, else #f.") #define FUNC_NAME s_scm_char_ci_less_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL((scm_upcase(SCM_ICHR(x))) < scm_upcase(SCM_ICHR(y))); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL((scm_upcase(SCM_CHAR(x))) < scm_upcase(SCM_CHAR(y))); } #undef FUNC_NAME @@ -144,9 +144,9 @@ SCM_DEFINE1 (scm_char_ci_leq_p, "char-ci<=?", scm_tc7_rpsubr, "Return #t iff X is less than or equal to Y in the Ascii sequence ignoring case, else #f.") #define FUNC_NAME s_scm_char_ci_leq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(scm_upcase(SCM_ICHR(x)) <= scm_upcase(SCM_ICHR(y))); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(scm_upcase(SCM_CHAR(x)) <= scm_upcase(SCM_CHAR(y))); } #undef FUNC_NAME @@ -155,9 +155,9 @@ SCM_DEFINE1 (scm_char_ci_gr_p, "char-ci>?", scm_tc7_rpsubr, "Return #t iff X is greater than Y in the Ascii sequence ignoring case, else #f.") #define FUNC_NAME s_scm_char_ci_gr_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(scm_upcase(SCM_ICHR(x)) > scm_upcase(SCM_ICHR(y))); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(scm_upcase(SCM_CHAR(x)) > scm_upcase(SCM_CHAR(y))); } #undef FUNC_NAME @@ -166,9 +166,9 @@ SCM_DEFINE1 (scm_char_ci_geq_p, "char-ci>=?", scm_tc7_rpsubr, "Return #t iff X is greater than or equal to Y in the Ascii sequence ignoring case, else #f.") #define FUNC_NAME s_scm_char_ci_geq_p { - SCM_VALIDATE_ICHR (1,x); - SCM_VALIDATE_ICHR (2,y); - return SCM_BOOL(scm_upcase(SCM_ICHR(x)) >= scm_upcase(SCM_ICHR(y))); + SCM_VALIDATE_CHAR (1,x); + SCM_VALIDATE_CHAR (2,y); + return SCM_BOOL(scm_upcase(SCM_CHAR(x)) >= scm_upcase(SCM_CHAR(y))); } #undef FUNC_NAME @@ -179,8 +179,8 @@ SCM_DEFINE (scm_char_alphabetic_p, "char-alphabetic?", 1, 0, 0, "Alphabetic means the same thing as the isalpha C library function.") #define FUNC_NAME s_scm_char_alphabetic_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && isalpha(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && isalpha(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -190,8 +190,8 @@ SCM_DEFINE (scm_char_numeric_p, "char-numeric?", 1, 0, 0, "Numeric means the same thing as the isdigit C library function.") #define FUNC_NAME s_scm_char_numeric_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && isdigit(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && isdigit(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -201,8 +201,8 @@ SCM_DEFINE (scm_char_whitespace_p, "char-whitespace?", 1, 0, 0, "Whitespace means the same thing as the isspace C library function.") #define FUNC_NAME s_scm_char_whitespace_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && isspace(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && isspace(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -214,8 +214,8 @@ SCM_DEFINE (scm_char_upper_case_p, "char-upper-case?", 1, 0, 0, "Uppercase means the same thing as the isupper C library function.") #define FUNC_NAME s_scm_char_upper_case_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && isupper(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && isupper(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -226,8 +226,8 @@ SCM_DEFINE (scm_char_lower_case_p, "char-lower-case?", 1, 0, 0, "Lowercase means the same thing as the islower C library function.") #define FUNC_NAME s_scm_char_lower_case_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && islower(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && islower(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -240,8 +240,8 @@ SCM_DEFINE (scm_char_is_both_p, "char-is-both?", 1, 0, 0, "C library functions.") #define FUNC_NAME s_scm_char_is_both_p { - SCM_VALIDATE_ICHR (1,chr); - return SCM_BOOL(isascii(SCM_ICHR(chr)) && (isupper(SCM_ICHR(chr)) || islower(SCM_ICHR(chr)))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_BOOL(isascii(SCM_CHAR(chr)) && (isupper(SCM_CHAR(chr)) || islower(SCM_CHAR(chr)))); } #undef FUNC_NAME @@ -253,8 +253,8 @@ SCM_DEFINE (scm_char_to_integer, "char->integer", 1, 0, 0, "Return the number corresponding to ordinal position of CHR in the Ascii sequence.") #define FUNC_NAME s_scm_char_to_integer { - SCM_VALIDATE_ICHR (1,chr); - return scm_ulong2num((unsigned long)SCM_ICHR(chr)); + SCM_VALIDATE_CHAR (1,chr); + return scm_ulong2num((unsigned long)SCM_CHAR(chr)); } #undef FUNC_NAME @@ -266,7 +266,7 @@ SCM_DEFINE (scm_integer_to_char, "integer->char", 1, 0, 0, #define FUNC_NAME s_scm_integer_to_char { SCM_VALIDATE_INUM_RANGE (1, n, 0, 256); - return SCM_MAKICHR (SCM_INUM (n)); + return SCM_MAKE_CHAR (SCM_INUM (n)); } #undef FUNC_NAME @@ -276,8 +276,8 @@ SCM_DEFINE (scm_char_upcase, "char-upcase", 1, 0, 0, "Return the uppercase character version of CHR.") #define FUNC_NAME s_scm_char_upcase { - SCM_VALIDATE_ICHR (1,chr); - return SCM_MAKICHR(scm_upcase(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_MAKE_CHAR(scm_upcase(SCM_CHAR(chr))); } #undef FUNC_NAME @@ -287,8 +287,8 @@ SCM_DEFINE (scm_char_downcase, "char-downcase", 1, 0, 0, "Return the lowercase character version of CHR.") #define FUNC_NAME s_scm_char_downcase { - SCM_VALIDATE_ICHR (1,chr); - return SCM_MAKICHR(scm_downcase(SCM_ICHR(chr))); + SCM_VALIDATE_CHAR (1,chr); + return SCM_MAKE_CHAR(scm_downcase(SCM_CHAR(chr))); } #undef FUNC_NAME diff --git a/libguile/chars.h b/libguile/chars.h index cb0ee49e2..1cf0f01d7 100644 --- a/libguile/chars.h +++ b/libguile/chars.h @@ -49,9 +49,13 @@ /* Immediate Characters */ -#define SCM_ICHRP(x) (SCM_ITAG8(x) == scm_tc8_char) -#define SCM_ICHR(x) ((unsigned int)SCM_ITAG8_DATA(x)) -#define SCM_MAKICHR(x) SCM_MAKE_ITAG8(x, scm_tc8_char) +#define SCM_CHARP(x) (SCM_ITAG8(x) == scm_tc8_char) +#define SCM_CHAR(x) ((unsigned int)SCM_ITAG8_DATA(x)) +#define SCM_MAKE_CHAR(x) SCM_MAKE_ITAG8(x, scm_tc8_char) + +#define SCM_ICHRP(x) SCM_CHARP(x) /* deprecated */ +#define SCM_ICHR(x) SCM_CHAR(x) /* deprecated */ +#define SCM_MAKICHR(x) SCM_MAKE_CHAR(x) /* deprecated */ @@ -61,30 +65,30 @@ extern const char scm_charnums[]; -extern SCM scm_char_p SCM_P ((SCM x)); -extern SCM scm_char_eq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_less_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_leq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_gr_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_geq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_ci_eq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_ci_less_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_ci_leq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_ci_gr_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_ci_geq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_char_alphabetic_p SCM_P ((SCM chr)); -extern SCM scm_char_numeric_p SCM_P ((SCM chr)); -extern SCM scm_char_whitespace_p SCM_P ((SCM chr)); -extern SCM scm_char_upper_case_p SCM_P ((SCM chr)); -extern SCM scm_char_lower_case_p SCM_P ((SCM chr)); -extern SCM scm_char_is_both_p SCM_P ((SCM chr)); -extern SCM scm_char_to_integer SCM_P ((SCM chr)); -extern SCM scm_integer_to_char SCM_P ((SCM n)); -extern SCM scm_char_upcase SCM_P ((SCM chr)); -extern SCM scm_char_downcase SCM_P ((SCM chr)); -extern void scm_tables_prehistory SCM_P ((void)); -extern int scm_upcase SCM_P ((unsigned int c)); -extern int scm_downcase SCM_P ((unsigned int c)); -extern void scm_init_chars SCM_P ((void)); +extern SCM scm_char_p (SCM x); +extern SCM scm_char_eq_p (SCM x, SCM y); +extern SCM scm_char_less_p (SCM x, SCM y); +extern SCM scm_char_leq_p (SCM x, SCM y); +extern SCM scm_char_gr_p (SCM x, SCM y); +extern SCM scm_char_geq_p (SCM x, SCM y); +extern SCM scm_char_ci_eq_p (SCM x, SCM y); +extern SCM scm_char_ci_less_p (SCM x, SCM y); +extern SCM scm_char_ci_leq_p (SCM x, SCM y); +extern SCM scm_char_ci_gr_p (SCM x, SCM y); +extern SCM scm_char_ci_geq_p (SCM x, SCM y); +extern SCM scm_char_alphabetic_p (SCM chr); +extern SCM scm_char_numeric_p (SCM chr); +extern SCM scm_char_whitespace_p (SCM chr); +extern SCM scm_char_upper_case_p (SCM chr); +extern SCM scm_char_lower_case_p (SCM chr); +extern SCM scm_char_is_both_p (SCM chr); +extern SCM scm_char_to_integer (SCM chr); +extern SCM scm_integer_to_char (SCM n); +extern SCM scm_char_upcase (SCM chr); +extern SCM scm_char_downcase (SCM chr); +extern void scm_tables_prehistory (void); +extern int scm_upcase (unsigned int c); +extern int scm_downcase (unsigned int c); +extern void scm_init_chars (void); #endif /* SCM_CHARSH */ diff --git a/libguile/continuations.h b/libguile/continuations.h index f37058366..e1b494cb2 100644 --- a/libguile/continuations.h +++ b/libguile/continuations.h @@ -70,9 +70,9 @@ typedef struct -extern SCM scm_make_cont SCM_P ((SCM * answer)); -extern void scm_dynthrow SCM_P ((SCM *a)); -extern SCM scm_call_continuation SCM_P ((SCM cont, SCM val)); -extern void scm_init_continuations SCM_P ((void)); +extern SCM scm_make_cont (SCM * answer); +extern void scm_dynthrow (SCM *a); +extern SCM scm_call_continuation (SCM cont, SCM val); +extern void scm_init_continuations (void); #endif /* CONTINUATIONSH */ diff --git a/libguile/debug.h b/libguile/debug.h index a3e69bfd1..685800c63 100644 --- a/libguile/debug.h +++ b/libguile/debug.h @@ -86,7 +86,7 @@ extern scm_option scm_debug_opts[]; #define SCM_STACK_LIMIT scm_debug_opts[12].val #define SCM_N_DEBUG_OPTIONS 13 -extern SCM (*scm_ceval_ptr) SCM_P ((SCM exp, SCM env)); +extern SCM (*scm_ceval_ptr) (SCM exp, SCM env); extern int scm_debug_mode; extern int scm_check_entry_p, scm_check_apply_p, scm_check_exit_p; @@ -181,38 +181,38 @@ extern long scm_tc16_memoized; -extern SCM * scm_lookup_cstr SCM_P ((char *str, int len, SCM env)); -extern SCM * scm_lookup_soft SCM_P ((SCM var, SCM genv)); -extern SCM scm_evstr SCM_P ((char *str)); -extern SCM scm_eval_string SCM_P ((SCM str)); -extern int scm_ready_p SCM_P ((void)); -extern void debug_print SCM_P ((SCM obj)); -extern SCM scm_debug_object_p SCM_P ((SCM obj)); -extern SCM scm_local_eval SCM_P ((SCM exp, SCM env)); -extern SCM scm_reverse_lookup SCM_P ((SCM env, SCM data)); -extern SCM scm_start_stack SCM_P ((SCM id, SCM exp, SCM env)); -extern SCM scm_procedure_environment SCM_P ((SCM proc)); -extern SCM scm_procedure_source SCM_P ((SCM proc)); -extern SCM scm_procedure_name SCM_P ((SCM proc)); -extern SCM scm_memoized_environment SCM_P ((SCM m)); -extern SCM scm_make_memoized SCM_P ((SCM exp, SCM env)); -extern SCM scm_memoized_p SCM_P ((SCM obj)); -extern SCM scm_with_traps SCM_P ((SCM thunk)); -extern SCM scm_evaluator_traps SCM_P ((SCM setting)); -extern SCM scm_debug_options SCM_P ((SCM setting)); -extern SCM scm_unmemoize SCM_P ((SCM memoized)); -extern SCM scm_make_debugobj SCM_P ((scm_debug_frame* debug)); -extern void scm_init_debug SCM_P ((void)); +extern SCM * scm_lookup_cstr (char *str, int len, SCM env); +extern SCM * scm_lookup_soft (SCM var, SCM genv); +extern SCM scm_evstr (char *str); +extern SCM scm_eval_string (SCM str); +extern int scm_ready_p (void); +extern void debug_print (SCM obj); +extern SCM scm_debug_object_p (SCM obj); +extern SCM scm_local_eval (SCM exp, SCM env); +extern SCM scm_reverse_lookup (SCM env, SCM data); +extern SCM scm_start_stack (SCM id, SCM exp, SCM env); +extern SCM scm_procedure_environment (SCM proc); +extern SCM scm_procedure_source (SCM proc); +extern SCM scm_procedure_name (SCM proc); +extern SCM scm_memoized_environment (SCM m); +extern SCM scm_make_memoized (SCM exp, SCM env); +extern SCM scm_memoized_p (SCM obj); +extern SCM scm_with_traps (SCM thunk); +extern SCM scm_evaluator_traps (SCM setting); +extern SCM scm_debug_options (SCM setting); +extern SCM scm_unmemoize (SCM memoized); +extern SCM scm_make_debugobj (scm_debug_frame* debug); +extern void scm_init_debug (void); #ifdef GUILE_DEBUG -extern SCM scm_make_gloc SCM_P ((SCM var, SCM env)); -extern SCM scm_gloc_p SCM_P ((SCM obj)); -extern SCM scm_make_iloc SCM_P ((SCM frame, SCM binding, SCM cdrp)); -extern SCM scm_iloc_p SCM_P ((SCM obj)); -extern SCM scm_memcons SCM_P ((SCM car, SCM cdr, SCM env)); -extern SCM scm_mem_to_proc SCM_P ((SCM obj)); -extern SCM scm_proc_to_mem SCM_P ((SCM obj)); -extern SCM scm_debug_hang SCM_P ((SCM obj)); +extern SCM scm_make_gloc (SCM var, SCM env); +extern SCM scm_gloc_p (SCM obj); +extern SCM scm_make_iloc (SCM frame, SCM binding, SCM cdrp); +extern SCM scm_iloc_p (SCM obj); +extern SCM scm_memcons (SCM car, SCM cdr, SCM env); +extern SCM scm_mem_to_proc (SCM obj); +extern SCM scm_proc_to_mem (SCM obj); +extern SCM scm_debug_hang (SCM obj); #endif /*GUILE_DEBUG*/ #endif /* DEBUGH */ diff --git a/libguile/dynl.h b/libguile/dynl.h index bca388e2c..a271a3d87 100644 --- a/libguile/dynl.h +++ b/libguile/dynl.h @@ -47,17 +47,17 @@ -void scm_register_module_xxx SCM_P ((char *module_name, void *init_func)); -SCM scm_registered_modules SCM_P ((void)); -SCM scm_clear_registered_modules SCM_P ((void)); +void scm_register_module_xxx (char *module_name, void *init_func); +SCM scm_registered_modules (void); +SCM scm_clear_registered_modules (void); -SCM scm_dynamic_link SCM_P ((SCM fname, SCM rest)); -SCM scm_dynamic_unlink SCM_P ((SCM dobj)); -SCM scm_dynamic_object_p SCM_P ((SCM obj)); -SCM scm_dynamic_func SCM_P ((SCM symb, SCM dobj)); -SCM scm_dynamic_call SCM_P ((SCM symb, SCM dobj)); -SCM scm_dynamic_args_call SCM_P ((SCM symb, SCM dobj, SCM args)); +SCM scm_dynamic_link (SCM fname, SCM rest); +SCM scm_dynamic_unlink (SCM dobj); +SCM scm_dynamic_object_p (SCM obj); +SCM scm_dynamic_func (SCM symb, SCM dobj); +SCM scm_dynamic_call (SCM symb, SCM dobj); +SCM scm_dynamic_args_call (SCM symb, SCM dobj, SCM args); -void scm_init_dynamic_linking SCM_P ((void)); +void scm_init_dynamic_linking (void); #endif /* LIBGUILE_DYNL_H */ diff --git a/libguile/dynwind.h b/libguile/dynwind.h index 49db3eef7..247f24ddb 100644 --- a/libguile/dynwind.h +++ b/libguile/dynwind.h @@ -50,17 +50,17 @@ typedef void (*scm_guard_t) (void *); typedef SCM (*scm_inner_t) (void *); -extern SCM scm_dynamic_wind SCM_P ((SCM thunk1, SCM thunk2, SCM thunk3)); -extern SCM scm_internal_dynamic_wind SCM_P ((scm_guard_t before, - scm_inner_t inner, - scm_guard_t after, - void *inner_data, - void *guard_data)); -extern void scm_dowinds SCM_P ((SCM to, long delta)); -extern void scm_init_dynwind SCM_P ((void)); +extern SCM scm_dynamic_wind (SCM thunk1, SCM thunk2, SCM thunk3); +extern SCM scm_internal_dynamic_wind (scm_guard_t before, + scm_inner_t inner, + scm_guard_t after, + void *inner_data, + void *guard_data); +extern void scm_dowinds (SCM to, long delta); +extern void scm_init_dynwind (void); #ifdef GUILE_DEBUG -extern SCM scm_wind_chain SCM_P ((void)); +extern SCM scm_wind_chain (void); #endif /*GUILE_DEBUG*/ #endif /* DYNWINDH */ diff --git a/libguile/eq.h b/libguile/eq.h index 9f8e60e5c..82977c0e3 100644 --- a/libguile/eq.h +++ b/libguile/eq.h @@ -47,9 +47,9 @@ -extern SCM scm_eq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_eqv_p SCM_P ((SCM x, SCM y)); -extern SCM scm_equal_p SCM_P ((SCM x, SCM y)); -extern void scm_init_eq SCM_P ((void)); +extern SCM scm_eq_p (SCM x, SCM y); +extern SCM scm_eqv_p (SCM x, SCM y); +extern SCM scm_equal_p (SCM x, SCM y); +extern void scm_init_eq (void); #endif /* EQH */ diff --git a/libguile/error.h b/libguile/error.h index 42cd6f9ca..81a79ff46 100644 --- a/libguile/error.h +++ b/libguile/error.h @@ -59,29 +59,29 @@ extern int scm_ints_disabled; #define SCM_NORETURN #endif -extern void scm_error SCM_P ((SCM key, const char *subr, const char *message, - SCM args, SCM rest)) SCM_NORETURN; -extern SCM scm_error_scm SCM_P ((SCM key, SCM subr, SCM message, - SCM args, SCM rest)) SCM_NORETURN; +extern void scm_error (SCM key, const char *subr, const char *message, + SCM args, SCM rest) SCM_NORETURN; +extern SCM scm_error_scm (SCM key, SCM subr, SCM message, + SCM args, SCM rest) SCM_NORETURN; extern SCM scm_strerror (SCM err); -extern void scm_syserror SCM_P ((const char *subr)) SCM_NORETURN; -extern void scm_syserror_msg SCM_P ((const char *subr, const char *message, - SCM args, int eno)) SCM_NORETURN; +extern void scm_syserror (const char *subr) SCM_NORETURN; +extern void scm_syserror_msg (const char *subr, const char *message, + SCM args, int eno) SCM_NORETURN; /* scm_sysmissing is no longer used in libguile. it can probably be removed after a release or two (2000-01-09). */ -extern void scm_sysmissing SCM_P ((const char *subr)) SCM_NORETURN; -extern void scm_num_overflow SCM_P ((const char *subr)) SCM_NORETURN; -extern void scm_out_of_range SCM_P ((const char *subr, SCM bad_value)) +extern void scm_sysmissing (const char *subr) SCM_NORETURN; +extern void scm_num_overflow (const char *subr) SCM_NORETURN; +extern void scm_out_of_range (const char *subr, SCM bad_value) SCM_NORETURN; -extern void scm_out_of_range_pos SCM_P ((const char *subr, SCM bad_value, SCM pos)) +extern void scm_out_of_range_pos (const char *subr, SCM bad_value, SCM pos) SCM_NORETURN; -extern void scm_wrong_num_args SCM_P ((SCM proc)) SCM_NORETURN; -extern void scm_wrong_type_arg SCM_P ((const char *subr, int pos, - SCM bad_value)) SCM_NORETURN; -extern void scm_memory_error SCM_P ((const char *subr)) SCM_NORETURN; -extern void scm_misc_error SCM_P ((const char *subr, const char *message, - SCM args)) SCM_NORETURN; -extern SCM scm_wta SCM_P ((SCM arg, const char *pos, const char *s_subr)); -extern void scm_init_error SCM_P ((void)); +extern void scm_wrong_num_args (SCM proc) SCM_NORETURN; +extern void scm_wrong_type_arg (const char *subr, int pos, + SCM bad_value) SCM_NORETURN; +extern void scm_memory_error (const char *subr) SCM_NORETURN; +extern void scm_misc_error (const char *subr, const char *message, + SCM args) SCM_NORETURN; +extern SCM scm_wta (SCM arg, const char *pos, const char *s_subr); +extern void scm_init_error (void); #endif /* ERRORH */ diff --git a/libguile/eval.c b/libguile/eval.c index 9bc21cf44..b257c2e55 100644 --- a/libguile/eval.c +++ b/libguile/eval.c @@ -462,7 +462,7 @@ SCM scm_sym_trace; -static void bodycheck SCM_P ((SCM xorig, SCM *bodyloc, const char *what)); +static void bodycheck (SCM xorig, SCM *bodyloc, const char *what); static void bodycheck (SCM xorig, SCM *bodyloc, const char *what) diff --git a/libguile/eval.h b/libguile/eval.h index 4ad053dda..1c05955b5 100644 --- a/libguile/eval.h +++ b/libguile/eval.h @@ -60,7 +60,7 @@ extern int scm_eval_stack; extern scm_option scm_evaluator_trap_table[]; -extern SCM scm_eval_options_interface SCM_P ((SCM setting)); +extern SCM scm_eval_options_interface (SCM setting); #define SCM_TRAPS_P scm_evaluator_trap_table[0].val #define SCM_ENTER_FRAME_P scm_evaluator_trap_table[1].val @@ -168,34 +168,34 @@ extern long scm_tc16_macro; -extern SCM * scm_ilookup SCM_P ((SCM iloc, SCM env)); -extern SCM * scm_lookupcar SCM_P ((SCM vloc, SCM genv, int check)); -extern SCM scm_unmemocar SCM_P ((SCM form, SCM env)); -extern SCM scm_unmemocopy SCM_P ((SCM form, SCM env)); -extern SCM scm_eval_car SCM_P ((SCM pair, SCM env)); +extern SCM * scm_ilookup (SCM iloc, SCM env); +extern SCM * scm_lookupcar (SCM vloc, SCM genv, int check); +extern SCM scm_unmemocar (SCM form, SCM env); +extern SCM scm_unmemocopy (SCM form, SCM env); +extern SCM scm_eval_car (SCM pair, SCM env); extern SCM scm_eval_body (SCM code, SCM env); -extern SCM scm_eval_args SCM_P ((SCM i, SCM env, SCM proc)); -extern SCM scm_deval_args SCM_P ((SCM l, SCM env, SCM proc, SCM *lloc)); -extern SCM scm_m_quote SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_begin SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_if SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_set_x SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_vref SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_vset SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_and SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_or SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_case SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_cond SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_lambda SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_letstar SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_do SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_quasiquote SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_delay SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_define SCM_P ((SCM x, SCM env)); -extern SCM scm_m_letrec SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_let SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_apply SCM_P ((SCM xorig, SCM env)); -extern SCM scm_m_cont SCM_P ((SCM xorig, SCM env)); +extern SCM scm_eval_args (SCM i, SCM env, SCM proc); +extern SCM scm_deval_args (SCM l, SCM env, SCM proc, SCM *lloc); +extern SCM scm_m_quote (SCM xorig, SCM env); +extern SCM scm_m_begin (SCM xorig, SCM env); +extern SCM scm_m_if (SCM xorig, SCM env); +extern SCM scm_m_set_x (SCM xorig, SCM env); +extern SCM scm_m_vref (SCM xorig, SCM env); +extern SCM scm_m_vset (SCM xorig, SCM env); +extern SCM scm_m_and (SCM xorig, SCM env); +extern SCM scm_m_or (SCM xorig, SCM env); +extern SCM scm_m_case (SCM xorig, SCM env); +extern SCM scm_m_cond (SCM xorig, SCM env); +extern SCM scm_m_lambda (SCM xorig, SCM env); +extern SCM scm_m_letstar (SCM xorig, SCM env); +extern SCM scm_m_do (SCM xorig, SCM env); +extern SCM scm_m_quasiquote (SCM xorig, SCM env); +extern SCM scm_m_delay (SCM xorig, SCM env); +extern SCM scm_m_define (SCM x, SCM env); +extern SCM scm_m_letrec (SCM xorig, SCM env); +extern SCM scm_m_let (SCM xorig, SCM env); +extern SCM scm_m_apply (SCM xorig, SCM env); +extern SCM scm_m_cont (SCM xorig, SCM env); extern SCM scm_m_nil_cond (SCM xorig, SCM env); extern SCM scm_m_nil_ify (SCM xorig, SCM env); extern SCM scm_m_t_ify (SCM xorig, SCM env); @@ -204,26 +204,26 @@ extern SCM scm_m_0_ify (SCM xorig, SCM env); extern SCM scm_m_1_ify (SCM xorig, SCM env); extern SCM scm_m_atfop (SCM xorig, SCM env); extern SCM scm_m_atbind (SCM xorig, SCM env); -extern int scm_badargsp SCM_P ((SCM formals, SCM args)); -extern SCM scm_ceval SCM_P ((SCM x, SCM env)); -extern SCM scm_deval SCM_P ((SCM x, SCM env)); -extern SCM scm_nconc2last SCM_P ((SCM lst)); -extern SCM scm_apply SCM_P ((SCM proc, SCM arg1, SCM args)); -extern SCM scm_dapply SCM_P ((SCM proc, SCM arg1, SCM args)); -extern SCM scm_m_expand_body SCM_P ((SCM xorig, SCM env)); -extern SCM scm_macroexp SCM_P ((SCM x, SCM env)); -extern SCM scm_map SCM_P ((SCM proc, SCM arg1, SCM args)); -extern SCM scm_for_each SCM_P ((SCM proc, SCM arg1, SCM args)); -extern SCM scm_closure SCM_P ((SCM code, SCM env)); -extern SCM scm_makprom SCM_P ((SCM code)); -extern SCM scm_force SCM_P ((SCM x)); -extern SCM scm_promise_p SCM_P ((SCM x)); +extern int scm_badargsp (SCM formals, SCM args); +extern SCM scm_ceval (SCM x, SCM env); +extern SCM scm_deval (SCM x, SCM env); +extern SCM scm_nconc2last (SCM lst); +extern SCM scm_apply (SCM proc, SCM arg1, SCM args); +extern SCM scm_dapply (SCM proc, SCM arg1, SCM args); +extern SCM scm_m_expand_body (SCM xorig, SCM env); +extern SCM scm_macroexp (SCM x, SCM env); +extern SCM scm_map (SCM proc, SCM arg1, SCM args); +extern SCM scm_for_each (SCM proc, SCM arg1, SCM args); +extern SCM scm_closure (SCM code, SCM env); +extern SCM scm_makprom (SCM code); +extern SCM scm_force (SCM x); +extern SCM scm_promise_p (SCM x); extern SCM scm_cons_source (SCM xorig, SCM x, SCM y); -extern SCM scm_copy_tree SCM_P ((SCM obj)); -extern SCM scm_eval_3 SCM_P ((SCM obj, int copyp, SCM env)); -extern SCM scm_eval2 SCM_P ((SCM obj, SCM env_thunk)); -extern SCM scm_eval SCM_P ((SCM obj)); -extern SCM scm_eval_x SCM_P ((SCM obj)); -extern void scm_init_eval SCM_P ((void)); +extern SCM scm_copy_tree (SCM obj); +extern SCM scm_eval_3 (SCM obj, int copyp, SCM env); +extern SCM scm_eval2 (SCM obj, SCM env_thunk); +extern SCM scm_eval (SCM obj); +extern SCM scm_eval_x (SCM obj); +extern void scm_init_eval (void); #endif /* EVALH */ diff --git a/libguile/filesys.h b/libguile/filesys.h index c503f4fea..d5bb7fbe6 100644 --- a/libguile/filesys.h +++ b/libguile/filesys.h @@ -57,35 +57,35 @@ extern long scm_tc16_dir; #define SCM_OPDIRP(x) (SCM_NIMP(x) && (SCM_CAR(x)==(scm_tc16_dir | SCM_OPN))) -extern SCM scm_chown SCM_P ((SCM object, SCM owner, SCM group)); -extern SCM scm_chmod SCM_P ((SCM object, SCM mode)); -extern SCM scm_umask SCM_P ((SCM mode)); +extern SCM scm_chown (SCM object, SCM owner, SCM group); +extern SCM scm_chmod (SCM object, SCM mode); +extern SCM scm_umask (SCM mode); extern SCM scm_open_fdes (SCM path, SCM flags, SCM mode); extern SCM scm_open (SCM path, SCM flags, SCM mode); extern SCM scm_close (SCM fd_or_port); -extern SCM scm_stat SCM_P ((SCM object)); -extern SCM scm_link SCM_P ((SCM oldpath, SCM newpath)); -extern SCM scm_rename SCM_P ((SCM oldname, SCM newname)); -extern SCM scm_delete_file SCM_P ((SCM str)); -extern SCM scm_mkdir SCM_P ((SCM path, SCM mode)); -extern SCM scm_rmdir SCM_P ((SCM path)); +extern SCM scm_stat (SCM object); +extern SCM scm_link (SCM oldpath, SCM newpath); +extern SCM scm_rename (SCM oldname, SCM newname); +extern SCM scm_delete_file (SCM str); +extern SCM scm_mkdir (SCM path, SCM mode); +extern SCM scm_rmdir (SCM path); extern SCM scm_directory_stream_p (SCM obj); -extern SCM scm_opendir SCM_P ((SCM dirname)); -extern SCM scm_readdir SCM_P ((SCM port)); -extern SCM scm_rewinddir SCM_P ((SCM port)); -extern SCM scm_closedir SCM_P ((SCM port)); -extern SCM scm_chdir SCM_P ((SCM str)); -extern SCM scm_getcwd SCM_P ((void)); -extern SCM scm_select SCM_P ((SCM reads, SCM writes, SCM excepts, SCM secs, SCM msecs)); +extern SCM scm_opendir (SCM dirname); +extern SCM scm_readdir (SCM port); +extern SCM scm_rewinddir (SCM port); +extern SCM scm_closedir (SCM port); +extern SCM scm_chdir (SCM str); +extern SCM scm_getcwd (void); +extern SCM scm_select (SCM reads, SCM writes, SCM excepts, SCM secs, SCM msecs); extern SCM scm_fcntl (SCM object, SCM cmd, SCM value); extern SCM scm_fsync (SCM object); -extern SCM scm_symlink SCM_P ((SCM oldpath, SCM newpath)); -extern SCM scm_readlink SCM_P ((SCM path)); -extern SCM scm_lstat SCM_P ((SCM str)); -extern SCM scm_copy_file SCM_P ((SCM oldfile, SCM newfile)); -extern SCM scm_dirname SCM_P ((SCM filename)); -extern SCM scm_basename SCM_P ((SCM filename, SCM suffix)); +extern SCM scm_symlink (SCM oldpath, SCM newpath); +extern SCM scm_readlink (SCM path); +extern SCM scm_lstat (SCM str); +extern SCM scm_copy_file (SCM oldfile, SCM newfile); +extern SCM scm_dirname (SCM filename); +extern SCM scm_basename (SCM filename, SCM suffix); -extern void scm_init_filesys SCM_P ((void)); +extern void scm_init_filesys (void); #endif /* FILESYSH */ diff --git a/libguile/fluids.h b/libguile/fluids.h index 10d7a9431..83ccbbe38 100644 --- a/libguile/fluids.h +++ b/libguile/fluids.h @@ -90,20 +90,20 @@ SCM_FLUID_NUM, not the fluid itself. */ #define SCM_FAST_FLUID_REF(n) (SCM_VELTS(scm_root->fluids)[n]) #define SCM_FAST_FLUID_SET_X(n, val) (SCM_VELTS(scm_root->fluids)[n] = val) -SCM scm_make_fluid SCM_P ((void)); -SCM scm_fluid_p SCM_P ((SCM fl)); -SCM scm_fluid_ref SCM_P ((SCM fluid)); -SCM scm_fluid_set_x SCM_P ((SCM fluid, SCM value)); +SCM scm_make_fluid (void); +SCM scm_fluid_p (SCM fl); +SCM scm_fluid_ref (SCM fluid); +SCM scm_fluid_set_x (SCM fluid, SCM value); -SCM scm_internal_with_fluids SCM_P ((SCM fluids, SCM vals, - SCM (*cproc)(void *), void *cdata)); -SCM scm_with_fluids SCM_P ((SCM fluids, SCM vals, SCM thunk)); +SCM scm_internal_with_fluids (SCM fluids, SCM vals, + SCM (*cproc)(void *), void *cdata); +SCM scm_with_fluids (SCM fluids, SCM vals, SCM thunk); -SCM scm_make_initial_fluids SCM_P ((void)); -void scm_copy_fluids SCM_P ((scm_root_state *)); -void scm_swap_fluids SCM_P ((SCM fluids, SCM vals)); -void scm_swap_fluids_reverse SCM_P ((SCM fluids, SCM vals)); +SCM scm_make_initial_fluids (void); +void scm_copy_fluids (scm_root_state *); +void scm_swap_fluids (SCM fluids, SCM vals); +void scm_swap_fluids_reverse (SCM fluids, SCM vals); -void scm_init_fluids SCM_P ((void)); +void scm_init_fluids (void); #endif /* !FLUIDSH */ diff --git a/libguile/fports.h b/libguile/fports.h index dcd0f1928..d720621f4 100644 --- a/libguile/fports.h +++ b/libguile/fports.h @@ -76,6 +76,6 @@ extern void scm_setfileno (FILE *fs, int fd); extern void scm_evict_ports (int fd); extern SCM scm_open_file (SCM filename, SCM modes); extern SCM scm_fdes_to_port (int fdes, char *mode, SCM name); -extern void scm_init_fports SCM_P ((void)); +extern void scm_init_fports (void); #endif /* FPORTSH */ diff --git a/libguile/gdb_interface.h b/libguile/gdb_interface.h index b8d5324d0..2fcbf9507 100644 --- a/libguile/gdb_interface.h +++ b/libguile/gdb_interface.h @@ -83,7 +83,7 @@ extern int gdb_output_length; In the "lisp/c" language mode, this is used to heuristically discriminate lisp values from C values during printing. */ -extern int gdb_maybe_valid_type_p SCM_P ((GDB_TYPE value)); +extern int gdb_maybe_valid_type_p (GDB_TYPE value); /* Parse expression in string STR. Store result in GDB_RESULT, then return 0 to indicate success. On error, return -1 to indicate @@ -92,7 +92,7 @@ extern int gdb_maybe_valid_type_p SCM_P ((GDB_TYPE value)); no message is passed. Please note that the resulting value should be protected against garbage collection. */ -extern int gdb_read SCM_P ((char *str)); +extern int gdb_read (char *str); /* Evaluate expression EXP. Store result in GDB_RESULT, then return 0 to indicate success. On error, return -1 to indicate failure. Any @@ -101,7 +101,7 @@ extern int gdb_read SCM_P ((char *str)); if no output is passed. Please note that the resulting lisp object should be protected against garbage collection. */ -extern int gdb_eval SCM_P ((GDB_TYPE exp)); +extern int gdb_eval (GDB_TYPE exp); /* Print VALUE. Store output in GDB_OUTPUT and GDB_OUTPUT_LENGTH. Return 0 to indicate success. On error, return -1 to indicate @@ -109,7 +109,7 @@ extern int gdb_eval SCM_P ((GDB_TYPE exp)); failure. Note that this function should be robust against strange values. It could in fact be passed any kind of value. */ -extern int gdb_print SCM_P ((GDB_TYPE value)); +extern int gdb_print (GDB_TYPE value); /* Bind NAME to VALUE in interpreter. (GDB has previously obtained NAME by passing a string to gdb_read.) Return 0 to indicate @@ -121,6 +121,6 @@ extern int gdb_print SCM_P ((GDB_TYPE value)); For scheme interpreters, this function should introduce top-level bindings. */ -extern int gdb_binding SCM_P ((GDB_TYPE name, GDB_TYPE value)); +extern int gdb_binding (GDB_TYPE name, GDB_TYPE value); #endif /* GDB_INTERFACE_H */ diff --git a/libguile/gdbint.h b/libguile/gdbint.h index e4e02b997..65f6ebfb9 100644 --- a/libguile/gdbint.h +++ b/libguile/gdbint.h @@ -53,6 +53,6 @@ extern int scm_print_carefully_p; -extern void scm_init_gdbint SCM_P ((void)); +extern void scm_init_gdbint (void); #endif /* GDBINTH */ diff --git a/libguile/gh_data.c b/libguile/gh_data.c index cd4d838e3..986bd55e3 100644 --- a/libguile/gh_data.c +++ b/libguile/gh_data.c @@ -82,7 +82,7 @@ gh_double2scm (double x) SCM gh_char2scm (char c) { - return SCM_MAKICHR (c); + return SCM_MAKE_CHAR (c); } SCM gh_str2scm (const char *s, int len) @@ -254,7 +254,7 @@ gh_scm2double (SCM obj) char gh_scm2char (SCM obj) { - return SCM_ICHR (obj); + return SCM_CHAR (obj); } /* Convert a vector, weak vector, string, substring or uniform vector diff --git a/libguile/gsubr.h b/libguile/gsubr.h index 1aa0209fa..2a0c47de4 100644 --- a/libguile/gsubr.h +++ b/libguile/gsubr.h @@ -59,15 +59,15 @@ extern SCM scm_f_gsubr_apply; -extern SCM scm_make_gsubr SCM_P ((const char *name, int req, int opt, int rst, - SCM (*fcn)())); -extern SCM scm_make_gsubr_with_generic SCM_P ((const char *name, - int req, - int opt, - int rst, - SCM (*fcn)(), - SCM *gf)); -extern SCM scm_gsubr_apply SCM_P ((SCM args)); -extern void scm_init_gsubr SCM_P ((void)); +extern SCM scm_make_gsubr (const char *name, int req, int opt, int rst, + SCM (*fcn)()); +extern SCM scm_make_gsubr_with_generic (const char *name, + int req, + int opt, + int rst, + SCM (*fcn)(), + SCM *gf); +extern SCM scm_gsubr_apply (SCM args); +extern void scm_init_gsubr (void); #endif /* GSUBRH */ diff --git a/libguile/hash.c b/libguile/hash.c index edc1a68d1..d93c6010f 100644 --- a/libguile/hash.c +++ b/libguile/hash.c @@ -64,8 +64,8 @@ scm_hasher(SCM obj, unsigned long n, scm_sizet d) case 2: case 6: /* SCM_INUMP(obj) */ return SCM_INUM(obj) % n; case 4: - if SCM_ICHRP(obj) - return (unsigned)(scm_downcase(SCM_ICHR(obj))) % n; + if SCM_CHARP(obj) + return (unsigned)(scm_downcase(SCM_CHAR(obj))) % n; switch ((int) obj) { #ifndef SICP case (int) SCM_EOL: d = 256; break; @@ -166,8 +166,8 @@ SCM_DEFINE (scm_hashq, "hashq", 2, 0, 0, unsigned int scm_ihashv (SCM obj, unsigned int n) { - if (SCM_ICHRP(obj)) - return ((unsigned int)(scm_downcase(SCM_ICHR(obj)))) % n; /* downcase!?!! */ + if (SCM_CHARP(obj)) + return ((unsigned int)(scm_downcase(SCM_CHAR(obj)))) % n; /* downcase!?!! */ if (SCM_NUMP(obj)) return (unsigned int) scm_hasher(obj, n, 10); diff --git a/libguile/hash.h b/libguile/hash.h index 884459d57..0ad0f3a5b 100644 --- a/libguile/hash.h +++ b/libguile/hash.h @@ -48,13 +48,13 @@ -extern unsigned long scm_hasher SCM_P ((SCM obj, unsigned long n, scm_sizet d)); -extern unsigned int scm_ihashq SCM_P ((SCM obj, unsigned int n)); -extern SCM scm_hashq SCM_P ((SCM obj, SCM n)); -extern unsigned int scm_ihashv SCM_P ((SCM obj, unsigned int n)); -extern SCM scm_hashv SCM_P ((SCM obj, SCM n)); -extern unsigned int scm_ihash SCM_P ((SCM obj, unsigned int n)); -extern SCM scm_hash SCM_P ((SCM obj, SCM n)); -extern void scm_init_hash SCM_P ((void)); +extern unsigned long scm_hasher (SCM obj, unsigned long n, scm_sizet d); +extern unsigned int scm_ihashq (SCM obj, unsigned int n); +extern SCM scm_hashq (SCM obj, SCM n); +extern unsigned int scm_ihashv (SCM obj, unsigned int n); +extern SCM scm_hashv (SCM obj, SCM n); +extern unsigned int scm_ihash (SCM obj, unsigned int n); +extern SCM scm_hash (SCM obj, SCM n); +extern void scm_init_hash (void); #endif /* HASHH */ diff --git a/libguile/hashtab.h b/libguile/hashtab.h index 9744fcf53..46fd91511 100644 --- a/libguile/hashtab.h +++ b/libguile/hashtab.h @@ -48,39 +48,39 @@ #if 0 -typedef unsigned int scm_hash_fn_t SCM_P ((SCM obj, unsigned int d, void *closure)); -typedef SCM scm_assoc_fn_t SCM_P ((SCM key, SCM alist, void *closure)); -typedef SCM scm_delete_fn_t SCM_P ((SCM elt, SCM list)); +typedef unsigned int scm_hash_fn_t (SCM obj, unsigned int d, void *closure); +typedef SCM scm_assoc_fn_t (SCM key, SCM alist, void *closure); +typedef SCM scm_delete_fn_t (SCM elt, SCM list); #endif -extern SCM scm_hash_fn_get_handle SCM_P ((SCM table, SCM obj, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure)); -extern SCM scm_hash_fn_create_handle_x SCM_P ((SCM table, SCM obj, SCM init, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure)); -extern SCM scm_hash_fn_ref SCM_P ((SCM table, SCM obj, SCM dflt, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure)); -extern SCM scm_hash_fn_set_x SCM_P ((SCM table, SCM obj, SCM val, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure)); -extern SCM scm_hash_fn_remove_x SCM_P ((SCM table, SCM obj, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), SCM (*delete_fn) (), void * closure)); -extern SCM scm_internal_hash_fold SCM_P ((SCM (*fn) (), void *closure, SCM init, SCM table)); +extern SCM scm_hash_fn_get_handle (SCM table, SCM obj, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure); +extern SCM scm_hash_fn_create_handle_x (SCM table, SCM obj, SCM init, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure); +extern SCM scm_hash_fn_ref (SCM table, SCM obj, SCM dflt, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure); +extern SCM scm_hash_fn_set_x (SCM table, SCM obj, SCM val, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), void * closure); +extern SCM scm_hash_fn_remove_x (SCM table, SCM obj, unsigned int (*hash_fn) (), SCM (*assoc_fn) (), SCM (*delete_fn) (), void * closure); +extern SCM scm_internal_hash_fold (SCM (*fn) (), void *closure, SCM init, SCM table); -extern SCM scm_hashq_get_handle SCM_P ((SCM table, SCM obj)); -extern SCM scm_hashq_create_handle_x SCM_P ((SCM table, SCM obj, SCM init)); -extern SCM scm_hashq_ref SCM_P ((SCM table, SCM obj, SCM dflt)); -extern SCM scm_hashq_set_x SCM_P ((SCM table, SCM obj, SCM val)); -extern SCM scm_hashq_remove_x SCM_P ((SCM table, SCM obj)); -extern SCM scm_hashv_get_handle SCM_P ((SCM table, SCM obj)); -extern SCM scm_hashv_create_handle_x SCM_P ((SCM table, SCM obj, SCM init)); -extern SCM scm_hashv_ref SCM_P ((SCM table, SCM obj, SCM dflt)); -extern SCM scm_hashv_set_x SCM_P ((SCM table, SCM obj, SCM val)); -extern SCM scm_hashv_remove_x SCM_P ((SCM table, SCM obj)); -extern SCM scm_hash_get_handle SCM_P ((SCM table, SCM obj)); -extern SCM scm_hash_create_handle_x SCM_P ((SCM table, SCM obj, SCM init)); -extern SCM scm_hash_ref SCM_P ((SCM table, SCM obj, SCM dflt)); -extern SCM scm_hash_set_x SCM_P ((SCM table, SCM obj, SCM val)); -extern SCM scm_hash_remove_x SCM_P ((SCM table, SCM obj)); -extern SCM scm_hashx_get_handle SCM_P ((SCM hash, SCM assoc, SCM table, SCM obj)); -extern SCM scm_hashx_create_handle_x SCM_P ((SCM hash, SCM assoc, SCM table, SCM obj, SCM init)); -extern SCM scm_hashx_ref SCM_P ((SCM hash, SCM assoc, SCM table, SCM obj, SCM dflt)); -extern SCM scm_hashx_set_x SCM_P ((SCM hash, SCM assoc, SCM table, SCM obj, SCM val)); -extern SCM scm_hashx_remove_x SCM_P ((SCM hash, SCM assoc, SCM del, SCM table, SCM obj)); -extern SCM scm_hash_fold SCM_P ((SCM proc, SCM init, SCM hash)); -extern void scm_init_hashtab SCM_P ((void)); +extern SCM scm_hashq_get_handle (SCM table, SCM obj); +extern SCM scm_hashq_create_handle_x (SCM table, SCM obj, SCM init); +extern SCM scm_hashq_ref (SCM table, SCM obj, SCM dflt); +extern SCM scm_hashq_set_x (SCM table, SCM obj, SCM val); +extern SCM scm_hashq_remove_x (SCM table, SCM obj); +extern SCM scm_hashv_get_handle (SCM table, SCM obj); +extern SCM scm_hashv_create_handle_x (SCM table, SCM obj, SCM init); +extern SCM scm_hashv_ref (SCM table, SCM obj, SCM dflt); +extern SCM scm_hashv_set_x (SCM table, SCM obj, SCM val); +extern SCM scm_hashv_remove_x (SCM table, SCM obj); +extern SCM scm_hash_get_handle (SCM table, SCM obj); +extern SCM scm_hash_create_handle_x (SCM table, SCM obj, SCM init); +extern SCM scm_hash_ref (SCM table, SCM obj, SCM dflt); +extern SCM scm_hash_set_x (SCM table, SCM obj, SCM val); +extern SCM scm_hash_remove_x (SCM table, SCM obj); +extern SCM scm_hashx_get_handle (SCM hash, SCM assoc, SCM table, SCM obj); +extern SCM scm_hashx_create_handle_x (SCM hash, SCM assoc, SCM table, SCM obj, SCM init); +extern SCM scm_hashx_ref (SCM hash, SCM assoc, SCM table, SCM obj, SCM dflt); +extern SCM scm_hashx_set_x (SCM hash, SCM assoc, SCM table, SCM obj, SCM val); +extern SCM scm_hashx_remove_x (SCM hash, SCM assoc, SCM del, SCM table, SCM obj); +extern SCM scm_hash_fold (SCM proc, SCM init, SCM hash); +extern void scm_init_hashtab (void); #endif /* HASHTABH */ diff --git a/libguile/ioext.c b/libguile/ioext.c index 737fe3a55..0f07d1d48 100644 --- a/libguile/ioext.c +++ b/libguile/ioext.c @@ -120,7 +120,7 @@ SCM_DEFINE (scm_read_delimited_x, "%read-delimited!", 3, 3, 0, if (SCM_FALSEP (gobble)) scm_ungetc (c, port); - return scm_cons (SCM_MAKICHR (c), + return scm_cons (SCM_MAKE_CHAR (c), scm_long2num (j - cstart)); } } @@ -257,7 +257,7 @@ SCM_DEFINE (scm_read_line, "%read-line", 0, 1, 0, { if (s[slen-1] == '\n') { - term = SCM_MAKICHR ('\n'); + term = SCM_MAKE_CHAR ('\n'); s[slen-1] = '\0'; line = scm_take_str (s, slen-1); scm_done_malloc (-1); diff --git a/libguile/ioext.h b/libguile/ioext.h index e082e7a34..4e1b38eaf 100644 --- a/libguile/ioext.h +++ b/libguile/ioext.h @@ -48,18 +48,18 @@ -extern SCM scm_read_delimited_x SCM_P ((SCM delims, SCM buf, SCM gobble, SCM port, SCM offset, SCM length)); +extern SCM scm_read_delimited_x (SCM delims, SCM buf, SCM gobble, SCM port, SCM offset, SCM length); extern SCM scm_read_line (SCM port); -extern SCM scm_write_line SCM_P ((SCM obj, SCM port)); -extern SCM scm_ftell SCM_P ((SCM object)); -extern SCM scm_fseek SCM_P ((SCM object, SCM offset, SCM whence)); -extern SCM scm_redirect_port SCM_P ((SCM into_pt, SCM from_pt)); +extern SCM scm_write_line (SCM obj, SCM port); +extern SCM scm_ftell (SCM object); +extern SCM scm_fseek (SCM object, SCM offset, SCM whence); +extern SCM scm_redirect_port (SCM into_pt, SCM from_pt); extern SCM scm_dup_to_fdes (SCM fd_or_port, SCM newfd); -extern SCM scm_fileno SCM_P ((SCM port)); -extern SCM scm_isatty_p SCM_P ((SCM port)); -extern SCM scm_fdopen SCM_P ((SCM fdes, SCM modes)); -extern SCM scm_primitive_move_to_fdes SCM_P ((SCM port, SCM fd)); -extern SCM scm_fdes_to_ports SCM_P ((SCM fd)); -extern void scm_init_ioext SCM_P ((void)); +extern SCM scm_fileno (SCM port); +extern SCM scm_isatty_p (SCM port); +extern SCM scm_fdopen (SCM fdes, SCM modes); +extern SCM scm_primitive_move_to_fdes (SCM port, SCM fd); +extern SCM scm_fdes_to_ports (SCM fd); +extern void scm_init_ioext (void); #endif /* IOEXTH */ diff --git a/libguile/lang.h b/libguile/lang.h index 83485c247..ec18d4e23 100644 --- a/libguile/lang.h +++ b/libguile/lang.h @@ -66,6 +66,6 @@ extern SCM scm_nil_cdr (SCM x); extern SCM scm_null (SCM x); extern SCM scm_m_while (SCM exp, SCM env); extern SCM scm_nil_eq (SCM x, SCM y); -extern void scm_init_lang SCM_P ((void)); +extern void scm_init_lang (void); #endif /* PAIRSH */ diff --git a/libguile/list.c b/libguile/list.c index 16c52c71f..eabd18cfc 100644 --- a/libguile/list.c +++ b/libguile/list.c @@ -180,10 +180,20 @@ SCM_DEFINE (scm_length, "length", 1, 0, 0, SCM_DEFINE (scm_append, "append", 0, 0, 1, (SCM args), - "A destructive version of @code{append} (@pxref{Pairs and Lists,,,r4rs,\n" - "The Revised^4 Report on Scheme}). The cdr field of each list's final\n" - "pair is changed to point to the head of the next list, so no consing is\n" - "performed. Return a pointer to the mutated list.") + "Returns a list consisting of the elements of the first LIST\n" + "followed by the elements of the other LISTs.\n" + "\n" + " (append '(x) '(y)) => (x y)\n" + " (append '(a) '(b c d)) => (a b c d)\n" + " (append '(a (b)) '((c))) => (a (b) (c))\n" + "\n" + "The resulting list is always newly allocated, except that it shares\n" + "structure with the last LIST argument. The last argument may\n" + "actually be any object; an improper list results if the last\n" + "argument is not a proper list.\n" + + " (append '(a b) '(c . d)) => (a b c . d)\n" + " (append '() 'a) => a\n") #define FUNC_NAME s_scm_append { SCM res = SCM_EOL; @@ -214,7 +224,10 @@ SCM_DEFINE (scm_append, "append", 0, 0, 1, SCM_DEFINE (scm_append_x, "append!", 0, 0, 1, (SCM args), - "") + "A destructive version of @code{append} (@pxref{Pairs and Lists,,,r4rs,\n" + "The Revised^4 Report on Scheme}). The cdr field of each list's final\n" + "pair is changed to point to the head of the next list, so no consing is\n" + "performed. Return a pointer to the mutated list.") #define FUNC_NAME s_scm_append_x { SCM arg; diff --git a/libguile/load.h b/libguile/load.h index 68f21ab38..1800f2d29 100644 --- a/libguile/load.h +++ b/libguile/load.h @@ -46,17 +46,17 @@ #include "libguile/__scm.h" -extern SCM scm_internal_parse_path SCM_P ((char *path, SCM tail)); -extern SCM scm_parse_path SCM_P ((SCM path, SCM tail)); -extern void scm_init_load_path SCM_P ((void)); -extern SCM scm_primitive_load SCM_P ((SCM filename)); -extern SCM scm_sys_package_data_dir SCM_P ((void)); -extern SCM scm_sys_library_dir SCM_P ((void)); -extern SCM scm_sys_site_dir SCM_P ((void)); -extern SCM scm_search_path SCM_P ((SCM path, SCM filename, SCM exts)); -extern SCM scm_sys_search_load_path SCM_P ((SCM filename)); -extern SCM scm_primitive_load_path SCM_P ((SCM filename)); -extern SCM scm_read_and_eval_x SCM_P ((SCM port)); -extern void scm_init_load SCM_P ((void)); +extern SCM scm_internal_parse_path (char *path, SCM tail); +extern SCM scm_parse_path (SCM path, SCM tail); +extern void scm_init_load_path (void); +extern SCM scm_primitive_load (SCM filename); +extern SCM scm_sys_package_data_dir (void); +extern SCM scm_sys_library_dir (void); +extern SCM scm_sys_site_dir (void); +extern SCM scm_search_path (SCM path, SCM filename, SCM exts); +extern SCM scm_sys_search_load_path (SCM filename); +extern SCM scm_primitive_load_path (SCM filename); +extern SCM scm_read_and_eval_x (SCM port); +extern void scm_init_load (void); #endif /* LOADH */ diff --git a/libguile/macros.h b/libguile/macros.h index 1156a4b76..beef5aa5e 100644 --- a/libguile/macros.h +++ b/libguile/macros.h @@ -52,16 +52,16 @@ extern long scm_tc16_macro; -extern SCM scm_makacro SCM_P ((SCM code)); -extern SCM scm_makmacro SCM_P ((SCM code)); -extern SCM scm_makmmacro SCM_P ((SCM code)); -extern SCM scm_macro_p SCM_P ((SCM obj)); -extern SCM scm_macro_type SCM_P ((SCM m)); -extern SCM scm_macro_name SCM_P ((SCM m)); -extern SCM scm_macro_transformer SCM_P ((SCM m)); -extern SCM scm_make_synt SCM_P ((const char *name, - SCM (*macroizer) (SCM), - SCM (*fcn) ())); -extern void scm_init_macros SCM_P ((void)); +extern SCM scm_makacro (SCM code); +extern SCM scm_makmacro (SCM code); +extern SCM scm_makmmacro (SCM code); +extern SCM scm_macro_p (SCM obj); +extern SCM scm_macro_type (SCM m); +extern SCM scm_macro_name (SCM m); +extern SCM scm_macro_transformer (SCM m); +extern SCM scm_make_synt (const char *name, + SCM (*macroizer) (SCM), + SCM (*fcn) ()); +extern void scm_init_macros (void); #endif /* MACROSH */ diff --git a/libguile/mallocs.h b/libguile/mallocs.h index 4bc347ead..99504c853 100644 --- a/libguile/mallocs.h +++ b/libguile/mallocs.h @@ -54,7 +54,7 @@ extern int scm_tc16_malloc; -extern SCM scm_malloc_obj SCM_P ((scm_sizet n)); -extern void scm_init_mallocs SCM_P ((void)); +extern SCM scm_malloc_obj (scm_sizet n); +extern void scm_init_mallocs (void); #endif /* MALLOCSH */ diff --git a/libguile/modules.h b/libguile/modules.h index d3ae6a727..3983f068a 100644 --- a/libguile/modules.h +++ b/libguile/modules.h @@ -56,9 +56,9 @@ extern SCM scm_ensure_user_module (SCM name); extern SCM scm_module_lookup_closure (SCM module); extern SCM scm_resolve_module (SCM name); extern SCM scm_load_scheme_module (SCM name); -extern SCM scm_env_top_level SCM_P ((SCM env)); -extern SCM scm_top_level_env SCM_P ((SCM thunk)); -extern SCM scm_system_module_env_p SCM_P ((SCM env)); +extern SCM scm_env_top_level (SCM env); +extern SCM scm_top_level_env (SCM thunk); +extern SCM scm_system_module_env_p (SCM env); extern void scm_init_modules (void); extern void scm_post_boot_init_modules (void); diff --git a/libguile/net_db.h b/libguile/net_db.h index b84d7200b..7ea8620ff 100644 --- a/libguile/net_db.h +++ b/libguile/net_db.h @@ -51,19 +51,19 @@ -extern SCM scm_gethost SCM_P ((SCM name)); -extern SCM scm_inet_aton SCM_P ((SCM address)); -extern SCM scm_inet_ntoa SCM_P ((SCM inetid)); -extern SCM scm_inet_netof SCM_P ((SCM address)); -extern SCM scm_lnaof SCM_P ((SCM address)); -extern SCM scm_inet_makeaddr SCM_P ((SCM net, SCM lna)); -extern SCM scm_getnet SCM_P ((SCM name)); -extern SCM scm_getproto SCM_P ((SCM name)); -extern SCM scm_getserv SCM_P ((SCM name, SCM proto)); -extern SCM scm_sethost SCM_P ((SCM arg)); -extern SCM scm_setnet SCM_P ((SCM arg)); -extern SCM scm_setproto SCM_P ((SCM arg)); -extern SCM scm_setserv SCM_P ((SCM arg)); -extern void scm_init_net_db SCM_P ((void)); +extern SCM scm_gethost (SCM name); +extern SCM scm_inet_aton (SCM address); +extern SCM scm_inet_ntoa (SCM inetid); +extern SCM scm_inet_netof (SCM address); +extern SCM scm_lnaof (SCM address); +extern SCM scm_inet_makeaddr (SCM net, SCM lna); +extern SCM scm_getnet (SCM name); +extern SCM scm_getproto (SCM name); +extern SCM scm_getserv (SCM name, SCM proto); +extern SCM scm_sethost (SCM arg); +extern SCM scm_setnet (SCM arg); +extern SCM scm_setproto (SCM arg); +extern SCM scm_setserv (SCM arg); +extern void scm_init_net_db (void); #endif /* NETDBH */ diff --git a/libguile/numbers.h b/libguile/numbers.h index f09c1cba5..cfc2ba80d 100644 --- a/libguile/numbers.h +++ b/libguile/numbers.h @@ -246,99 +246,99 @@ typedef struct scm_dbl -extern SCM scm_exact_p SCM_P ((SCM x)); -extern SCM scm_odd_p SCM_P ((SCM n)); -extern SCM scm_even_p SCM_P ((SCM n)); -extern SCM scm_abs SCM_P ((SCM x)); -extern SCM scm_quotient SCM_P ((SCM x, SCM y)); -extern SCM scm_remainder SCM_P ((SCM x, SCM y)); -extern SCM scm_modulo SCM_P ((SCM x, SCM y)); -extern SCM scm_gcd SCM_P ((SCM x, SCM y)); -extern SCM scm_lcm SCM_P ((SCM n1, SCM n2)); -extern SCM scm_logand SCM_P ((SCM n1, SCM n2)); -extern SCM scm_logior SCM_P ((SCM n1, SCM n2)); -extern SCM scm_logxor SCM_P ((SCM n1, SCM n2)); -extern SCM scm_logtest SCM_P ((SCM n1, SCM n2)); -extern SCM scm_logbit_p SCM_P ((SCM n1, SCM n2)); -extern SCM scm_lognot SCM_P ((SCM n)); -extern SCM scm_integer_expt SCM_P ((SCM z1, SCM z2)); -extern SCM scm_ash SCM_P ((SCM n, SCM cnt)); -extern SCM scm_bit_extract SCM_P ((SCM n, SCM start, SCM end)); -extern SCM scm_logcount SCM_P ((SCM n)); -extern SCM scm_integer_length SCM_P ((SCM n)); -extern SCM scm_mkbig SCM_P ((scm_sizet nlen, int sign)); -extern SCM scm_big2inum SCM_P ((SCM b, scm_sizet l)); -extern SCM scm_adjbig SCM_P ((SCM b, scm_sizet nlen)); -extern SCM scm_normbig SCM_P ((SCM b)); -extern SCM scm_copybig SCM_P ((SCM b, int sign)); -extern SCM scm_long2big SCM_P ((long n)); -extern SCM scm_long_long2big SCM_P ((long_long n)); -extern SCM scm_2ulong2big SCM_P ((unsigned long * np)); -extern SCM scm_ulong2big SCM_P ((unsigned long n)); -extern int scm_bigcomp SCM_P ((SCM x, SCM y)); -extern long scm_pseudolong SCM_P ((long x)); -extern void scm_longdigs SCM_P ((long x, SCM_BIGDIG digs[])); -extern SCM scm_addbig SCM_P ((SCM_BIGDIG *x, scm_sizet nx, int xsgn, SCM bigy, int sgny)); -extern SCM scm_mulbig SCM_P ((SCM_BIGDIG *x, scm_sizet nx, SCM_BIGDIG *y, scm_sizet ny, int sgn)); -extern unsigned int scm_divbigdig SCM_P ((SCM_BIGDIG *ds, scm_sizet h, SCM_BIGDIG div)); -extern SCM scm_divbigint SCM_P ((SCM x, long z, int sgn, int mode)); -extern SCM scm_divbigbig SCM_P ((SCM_BIGDIG *x, scm_sizet nx, SCM_BIGDIG *y, scm_sizet ny, int sgn, int modes)); -extern scm_sizet scm_iint2str SCM_P ((long num, int rad, char *p)); -extern SCM scm_number_to_string SCM_P ((SCM x, SCM radix)); -extern int scm_floprint SCM_P ((SCM sexp, SCM port, scm_print_state *pstate)); -extern int scm_bigprint SCM_P ((SCM exp, SCM port, scm_print_state *pstate)); -extern SCM scm_istr2int SCM_P ((char *str, long len, long radix)); -extern SCM scm_istr2flo SCM_P ((char *str, long len, long radix)); -extern SCM scm_istring2number SCM_P ((char *str, long len, long radix)); -extern SCM scm_string_to_number SCM_P ((SCM str, SCM radix)); -extern SCM scm_makdbl SCM_P ((double x, double y)); -extern SCM scm_bigequal SCM_P ((SCM x, SCM y)); -extern SCM scm_floequal SCM_P ((SCM x, SCM y)); -extern SCM scm_number_p SCM_P ((SCM x)); -extern SCM scm_real_p SCM_P ((SCM x)); -extern SCM scm_integer_p SCM_P ((SCM x)); -extern SCM scm_inexact_p SCM_P ((SCM x)); -extern SCM scm_num_eq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_less_p SCM_P ((SCM x, SCM y)); -extern SCM scm_gr_p SCM_P ((SCM x, SCM y)); -extern SCM scm_leq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_geq_p SCM_P ((SCM x, SCM y)); -extern SCM scm_zero_p SCM_P ((SCM z)); -extern SCM scm_positive_p SCM_P ((SCM x)); -extern SCM scm_negative_p SCM_P ((SCM x)); -extern SCM scm_max SCM_P ((SCM x, SCM y)); -extern SCM scm_min SCM_P ((SCM x, SCM y)); -extern SCM scm_sum SCM_P ((SCM x, SCM y)); -extern SCM scm_difference SCM_P ((SCM x, SCM y)); -extern SCM scm_product SCM_P ((SCM x, SCM y)); -extern double scm_num2dbl SCM_P ((SCM a, const char * why)); -extern SCM scm_divide SCM_P ((SCM x, SCM y)); -extern double scm_asinh SCM_P ((double x)); -extern double scm_acosh SCM_P ((double x)); -extern double scm_atanh SCM_P ((double x)); -extern double scm_truncate SCM_P ((double x)); -extern double scm_round SCM_P ((double x)); -extern double scm_exact_to_inexact SCM_P ((double z)); -extern SCM scm_sys_expt SCM_P ((SCM z1, SCM z2)); -extern SCM scm_sys_atan2 SCM_P ((SCM z1, SCM z2)); -extern SCM scm_make_rectangular SCM_P ((SCM z1, SCM z2)); -extern SCM scm_make_polar SCM_P ((SCM z1, SCM z2)); -extern SCM scm_real_part SCM_P ((SCM z)); -extern SCM scm_imag_part SCM_P ((SCM z)); -extern SCM scm_magnitude SCM_P ((SCM z)); -extern SCM scm_angle SCM_P ((SCM z)); -extern SCM scm_inexact_to_exact SCM_P ((SCM z)); -extern SCM scm_trunc SCM_P ((SCM x)); -extern SCM scm_dbl2big SCM_P ((double d)); -extern double scm_big2dbl SCM_P ((SCM b)); -extern SCM scm_long2num SCM_P ((long sl)); -extern SCM scm_long_long2num SCM_P ((long_long sl)); -extern SCM scm_ulong2num SCM_P ((unsigned long sl)); -extern long scm_num2long SCM_P ((SCM num, char *pos, const char *s_caller)); -extern long_long scm_num2long_long SCM_P ((SCM num, char *pos, - const char *s_caller)); -extern unsigned long scm_num2ulong SCM_P ((SCM num, char *pos, - const char *s_caller)); -extern void scm_init_numbers SCM_P ((void)); +extern SCM scm_exact_p (SCM x); +extern SCM scm_odd_p (SCM n); +extern SCM scm_even_p (SCM n); +extern SCM scm_abs (SCM x); +extern SCM scm_quotient (SCM x, SCM y); +extern SCM scm_remainder (SCM x, SCM y); +extern SCM scm_modulo (SCM x, SCM y); +extern SCM scm_gcd (SCM x, SCM y); +extern SCM scm_lcm (SCM n1, SCM n2); +extern SCM scm_logand (SCM n1, SCM n2); +extern SCM scm_logior (SCM n1, SCM n2); +extern SCM scm_logxor (SCM n1, SCM n2); +extern SCM scm_logtest (SCM n1, SCM n2); +extern SCM scm_logbit_p (SCM n1, SCM n2); +extern SCM scm_lognot (SCM n); +extern SCM scm_integer_expt (SCM z1, SCM z2); +extern SCM scm_ash (SCM n, SCM cnt); +extern SCM scm_bit_extract (SCM n, SCM start, SCM end); +extern SCM scm_logcount (SCM n); +extern SCM scm_integer_length (SCM n); +extern SCM scm_mkbig (scm_sizet nlen, int sign); +extern SCM scm_big2inum (SCM b, scm_sizet l); +extern SCM scm_adjbig (SCM b, scm_sizet nlen); +extern SCM scm_normbig (SCM b); +extern SCM scm_copybig (SCM b, int sign); +extern SCM scm_long2big (long n); +extern SCM scm_long_long2big (long_long n); +extern SCM scm_2ulong2big (unsigned long * np); +extern SCM scm_ulong2big (unsigned long n); +extern int scm_bigcomp (SCM x, SCM y); +extern long scm_pseudolong (long x); +extern void scm_longdigs (long x, SCM_BIGDIG digs[]); +extern SCM scm_addbig (SCM_BIGDIG *x, scm_sizet nx, int xsgn, SCM bigy, int sgny); +extern SCM scm_mulbig (SCM_BIGDIG *x, scm_sizet nx, SCM_BIGDIG *y, scm_sizet ny, int sgn); +extern unsigned int scm_divbigdig (SCM_BIGDIG *ds, scm_sizet h, SCM_BIGDIG div); +extern SCM scm_divbigint (SCM x, long z, int sgn, int mode); +extern SCM scm_divbigbig (SCM_BIGDIG *x, scm_sizet nx, SCM_BIGDIG *y, scm_sizet ny, int sgn, int modes); +extern scm_sizet scm_iint2str (long num, int rad, char *p); +extern SCM scm_number_to_string (SCM x, SCM radix); +extern int scm_floprint (SCM sexp, SCM port, scm_print_state *pstate); +extern int scm_bigprint (SCM exp, SCM port, scm_print_state *pstate); +extern SCM scm_istr2int (char *str, long len, long radix); +extern SCM scm_istr2flo (char *str, long len, long radix); +extern SCM scm_istring2number (char *str, long len, long radix); +extern SCM scm_string_to_number (SCM str, SCM radix); +extern SCM scm_makdbl (double x, double y); +extern SCM scm_bigequal (SCM x, SCM y); +extern SCM scm_floequal (SCM x, SCM y); +extern SCM scm_number_p (SCM x); +extern SCM scm_real_p (SCM x); +extern SCM scm_integer_p (SCM x); +extern SCM scm_inexact_p (SCM x); +extern SCM scm_num_eq_p (SCM x, SCM y); +extern SCM scm_less_p (SCM x, SCM y); +extern SCM scm_gr_p (SCM x, SCM y); +extern SCM scm_leq_p (SCM x, SCM y); +extern SCM scm_geq_p (SCM x, SCM y); +extern SCM scm_zero_p (SCM z); +extern SCM scm_positive_p (SCM x); +extern SCM scm_negative_p (SCM x); +extern SCM scm_max (SCM x, SCM y); +extern SCM scm_min (SCM x, SCM y); +extern SCM scm_sum (SCM x, SCM y); +extern SCM scm_difference (SCM x, SCM y); +extern SCM scm_product (SCM x, SCM y); +extern double scm_num2dbl (SCM a, const char * why); +extern SCM scm_divide (SCM x, SCM y); +extern double scm_asinh (double x); +extern double scm_acosh (double x); +extern double scm_atanh (double x); +extern double scm_truncate (double x); +extern double scm_round (double x); +extern double scm_exact_to_inexact (double z); +extern SCM scm_sys_expt (SCM z1, SCM z2); +extern SCM scm_sys_atan2 (SCM z1, SCM z2); +extern SCM scm_make_rectangular (SCM z1, SCM z2); +extern SCM scm_make_polar (SCM z1, SCM z2); +extern SCM scm_real_part (SCM z); +extern SCM scm_imag_part (SCM z); +extern SCM scm_magnitude (SCM z); +extern SCM scm_angle (SCM z); +extern SCM scm_inexact_to_exact (SCM z); +extern SCM scm_trunc (SCM x); +extern SCM scm_dbl2big (double d); +extern double scm_big2dbl (SCM b); +extern SCM scm_long2num (long sl); +extern SCM scm_long_long2num (long_long sl); +extern SCM scm_ulong2num (unsigned long sl); +extern long scm_num2long (SCM num, char *pos, const char *s_caller); +extern long_long scm_num2long_long (SCM num, char *pos, + const char *s_caller); +extern unsigned long scm_num2ulong (SCM num, char *pos, + const char *s_caller); +extern void scm_init_numbers (void); #endif /* NUMBERSH */ diff --git a/libguile/objects.c b/libguile/objects.c index 483ef2b83..2486b4f7d 100644 --- a/libguile/objects.c +++ b/libguile/objects.c @@ -94,7 +94,7 @@ scm_class_of (SCM x) return scm_class_integer; case scm_tc3_imm24: - if (SCM_ICHRP (x)) + if (SCM_CHARP (x)) return scm_class_char; else { diff --git a/libguile/objects.h b/libguile/objects.h index 8cbd08fad..4b8d7b966 100644 --- a/libguile/objects.h +++ b/libguile/objects.h @@ -234,6 +234,6 @@ extern SCM scm_make_subclass_object (SCM c, SCM layout); extern SCM scm_i_make_class_object (SCM metaclass, SCM layout_string, unsigned long flags); -extern void scm_init_objects SCM_P ((void)); +extern void scm_init_objects (void); #endif /* OBJECTSH */ diff --git a/libguile/objprop.h b/libguile/objprop.h index 75424b1d6..f04c140c2 100644 --- a/libguile/objprop.h +++ b/libguile/objprop.h @@ -53,10 +53,10 @@ -extern SCM scm_object_properties SCM_P ((SCM obj)); -extern SCM scm_set_object_properties_x SCM_P ((SCM obj, SCM plist)); -extern SCM scm_object_property SCM_P ((SCM obj, SCM key)); -extern SCM scm_set_object_property_x SCM_P ((SCM obj, SCM key, SCM val)); -extern void scm_init_objprop SCM_P ((void)); +extern SCM scm_object_properties (SCM obj); +extern SCM scm_set_object_properties_x (SCM obj, SCM plist); +extern SCM scm_object_property (SCM obj, SCM key); +extern SCM scm_set_object_property_x (SCM obj, SCM key, SCM val); +extern void scm_init_objprop (void); #endif /* OBJPROPH */ diff --git a/libguile/options.h b/libguile/options.h index b79d24eca..5ab41c688 100644 --- a/libguile/options.h +++ b/libguile/options.h @@ -64,8 +64,8 @@ typedef struct scm_option #define SCM_OPTION_SCM 2 -extern SCM scm_options SCM_P ((SCM new_mode, scm_option options[], int n, const char *s)); -extern void scm_init_opts SCM_P ((SCM (*func) (SCM), scm_option options[], int n)); -extern void scm_init_options SCM_P ((void)); +extern SCM scm_options (SCM new_mode, scm_option options[], int n, const char *s); +extern void scm_init_opts (SCM (*func) (SCM), scm_option options[], int n); +extern void scm_init_options (void); #endif /* OPTIONSH */ diff --git a/libguile/pairs.h b/libguile/pairs.h index 2b184337a..07637b4b9 100644 --- a/libguile/pairs.h +++ b/libguile/pairs.h @@ -172,11 +172,11 @@ typedef SCM huge *SCMPTR; -extern SCM scm_cons SCM_P ((SCM x, SCM y)); -extern SCM scm_cons2 SCM_P ((SCM w, SCM x, SCM y)); -extern SCM scm_pair_p SCM_P ((SCM x)); -extern SCM scm_set_car_x SCM_P ((SCM pair, SCM value)); -extern SCM scm_set_cdr_x SCM_P ((SCM pair, SCM value)); -extern void scm_init_pairs SCM_P ((void)); +extern SCM scm_cons (SCM x, SCM y); +extern SCM scm_cons2 (SCM w, SCM x, SCM y); +extern SCM scm_pair_p (SCM x); +extern SCM scm_set_car_x (SCM pair, SCM value); +extern SCM scm_set_cdr_x (SCM pair, SCM value); +extern void scm_init_pairs (void); #endif /* PAIRSH */ diff --git a/libguile/ports.c b/libguile/ports.c index 4a59e134d..af1f8ffe0 100644 --- a/libguile/ports.c +++ b/libguile/ports.c @@ -762,7 +762,7 @@ SCM_DEFINE (scm_read_char, "read-char", 0, 1, 0, c = scm_getc (port); if (EOF == c) return SCM_EOF_VAL; - return SCM_MAKICHR (c); + return SCM_MAKE_CHAR (c); } #undef FUNC_NAME @@ -996,7 +996,7 @@ SCM_DEFINE (scm_peek_char, "peek-char", 0, 1, 0, if (EOF == c) return SCM_EOF_VAL; scm_ungetc (c, port); - return SCM_MAKICHR (c); + return SCM_MAKE_CHAR (c); } #undef FUNC_NAME @@ -1010,13 +1010,13 @@ SCM_DEFINE (scm_unread_char, "unread-char", 2, 0, 0, { int c; - SCM_VALIDATE_ICHR (1,cobj); + SCM_VALIDATE_CHAR (1,cobj); if (SCM_UNBNDP (port)) port = scm_cur_inp; else SCM_VALIDATE_OPINPORT (2,port); - c = SCM_ICHR (cobj); + c = SCM_CHAR (cobj); scm_ungetc (c, port); return cobj; diff --git a/libguile/posix.h b/libguile/posix.h index 3e1784d45..4b4369315 100644 --- a/libguile/posix.h +++ b/libguile/posix.h @@ -51,50 +51,50 @@ -extern SCM scm_tcsetpgrp SCM_P ((SCM port, SCM pgid)); -extern SCM scm_tcgetpgrp SCM_P ((SCM port)); -extern SCM scm_ctermid SCM_P ((void)); -extern SCM scm_setsid SCM_P ((void)); -extern SCM scm_setpgid SCM_P ((SCM pid, SCM pgid)); -extern SCM scm_pipe SCM_P ((void)); -extern SCM scm_getgroups SCM_P ((void)); -extern SCM scm_getpgrp SCM_P ((void)); -extern SCM scm_getpwuid SCM_P ((SCM user)); -extern SCM scm_setpwent SCM_P ((SCM arg)); -extern SCM scm_getgrgid SCM_P ((SCM name)); -extern SCM scm_setgrent SCM_P ((SCM arg)); -extern SCM scm_kill SCM_P ((SCM pid, SCM sig)); -extern SCM scm_waitpid SCM_P ((SCM pid, SCM options)); -extern SCM scm_status_exit_val SCM_P ((SCM status)); -extern SCM scm_status_term_sig SCM_P ((SCM status)); -extern SCM scm_status_stop_sig SCM_P ((SCM status)); -extern SCM scm_getppid SCM_P ((void)); -extern SCM scm_getuid SCM_P ((void)); -extern SCM scm_getgid SCM_P ((void)); -extern SCM scm_geteuid SCM_P ((void)); -extern SCM scm_getegid SCM_P ((void)); -extern SCM scm_setuid SCM_P ((SCM id)); -extern SCM scm_setgid SCM_P ((SCM id)); -extern SCM scm_seteuid SCM_P ((SCM id)); -extern SCM scm_setegid SCM_P ((SCM id)); -extern SCM scm_ttyname SCM_P ((SCM port)); -extern SCM scm_execl SCM_P ((SCM filename, SCM args)); -extern SCM scm_execlp SCM_P ((SCM filename, SCM args)); -extern SCM scm_execle SCM_P ((SCM filename, SCM env, SCM args)); -extern SCM scm_fork SCM_P ((void)); -extern SCM scm_uname SCM_P ((void)); -extern SCM scm_environ SCM_P ((SCM env)); -extern SCM scm_tmpnam SCM_P ((void)); -extern SCM scm_open_pipe SCM_P ((SCM pipestr, SCM modes)); -extern SCM scm_close_pipe SCM_P ((SCM port)); -extern SCM scm_utime SCM_P ((SCM pathname, SCM actime, SCM modtime)); -extern SCM scm_access SCM_P ((SCM path, SCM how)); -extern SCM scm_getpid SCM_P ((void)); -extern SCM scm_putenv SCM_P ((SCM str)); -extern SCM scm_setlocale SCM_P ((SCM category, SCM locale)); -extern SCM scm_mknod SCM_P ((SCM path, SCM type, SCM perms, SCM dev)); -extern SCM scm_nice SCM_P ((SCM incr)); -extern SCM scm_sync SCM_P ((void)); -extern void scm_init_posix SCM_P ((void)); +extern SCM scm_tcsetpgrp (SCM port, SCM pgid); +extern SCM scm_tcgetpgrp (SCM port); +extern SCM scm_ctermid (void); +extern SCM scm_setsid (void); +extern SCM scm_setpgid (SCM pid, SCM pgid); +extern SCM scm_pipe (void); +extern SCM scm_getgroups (void); +extern SCM scm_getpgrp (void); +extern SCM scm_getpwuid (SCM user); +extern SCM scm_setpwent (SCM arg); +extern SCM scm_getgrgid (SCM name); +extern SCM scm_setgrent (SCM arg); +extern SCM scm_kill (SCM pid, SCM sig); +extern SCM scm_waitpid (SCM pid, SCM options); +extern SCM scm_status_exit_val (SCM status); +extern SCM scm_status_term_sig (SCM status); +extern SCM scm_status_stop_sig (SCM status); +extern SCM scm_getppid (void); +extern SCM scm_getuid (void); +extern SCM scm_getgid (void); +extern SCM scm_geteuid (void); +extern SCM scm_getegid (void); +extern SCM scm_setuid (SCM id); +extern SCM scm_setgid (SCM id); +extern SCM scm_seteuid (SCM id); +extern SCM scm_setegid (SCM id); +extern SCM scm_ttyname (SCM port); +extern SCM scm_execl (SCM filename, SCM args); +extern SCM scm_execlp (SCM filename, SCM args); +extern SCM scm_execle (SCM filename, SCM env, SCM args); +extern SCM scm_fork (void); +extern SCM scm_uname (void); +extern SCM scm_environ (SCM env); +extern SCM scm_tmpnam (void); +extern SCM scm_open_pipe (SCM pipestr, SCM modes); +extern SCM scm_close_pipe (SCM port); +extern SCM scm_utime (SCM pathname, SCM actime, SCM modtime); +extern SCM scm_access (SCM path, SCM how); +extern SCM scm_getpid (void); +extern SCM scm_putenv (SCM str); +extern SCM scm_setlocale (SCM category, SCM locale); +extern SCM scm_mknod (SCM path, SCM type, SCM perms, SCM dev); +extern SCM scm_nice (SCM incr); +extern SCM scm_sync (void); +extern void scm_init_posix (void); #endif /* POSIXH */ diff --git a/libguile/print.c b/libguile/print.c index ee1f85aa7..71c9ff8bf 100644 --- a/libguile/print.c +++ b/libguile/print.c @@ -301,11 +301,11 @@ taloop: scm_intprint (SCM_INUM (exp), 10, port); break; case 4: - if (SCM_ICHRP (exp)) + if (SCM_CHARP (exp)) { register long i; - i = SCM_ICHR (exp); + i = SCM_CHAR (exp); if (SCM_WRITINGP (pstate)) { scm_puts ("#\\", port); @@ -1021,10 +1021,10 @@ SCM_DEFINE (scm_write_char, "write-char", 1, 1, 0, if (SCM_UNBNDP (port)) port = scm_cur_outp; - SCM_VALIDATE_ICHR (1,chr); + SCM_VALIDATE_CHAR (1,chr); SCM_VALIDATE_OPORT_VALUE (2,port); - scm_putc ((int) SCM_ICHR (chr), SCM_COERCE_OUTPORT (port)); + scm_putc ((int) SCM_CHAR (chr), SCM_COERCE_OUTPORT (port)); #ifdef HAVE_PIPE # ifdef EPIPE if (EPIPE == errno) diff --git a/libguile/print.h b/libguile/print.h index bea387821..cca9897c1 100644 --- a/libguile/print.h +++ b/libguile/print.h @@ -102,27 +102,27 @@ extern SCM scm_print_state_vtable; extern SCM scm_tc16_port_with_ps; -extern SCM scm_print_options SCM_P ((SCM setting)); -SCM scm_make_print_state SCM_P ((void)); -void scm_free_print_state SCM_P ((SCM print_state)); -extern void scm_intprint SCM_P ((long n, int radix, SCM port)); -extern void scm_ipruk SCM_P ((char *hdr, SCM ptr, SCM port)); -extern void scm_iprlist SCM_P ((char *hdr, SCM exp, int tlr, SCM port, scm_print_state *pstate)); -extern void scm_prin1 SCM_P ((SCM exp, SCM port, int writingp)); -extern void scm_iprin1 SCM_P ((SCM exp, SCM port, scm_print_state *pstate)); -extern SCM scm_write SCM_P ((SCM obj, SCM port)); -extern SCM scm_display SCM_P ((SCM obj, SCM port)); -extern SCM scm_simple_format SCM_P ((SCM port, SCM message, SCM args)); -extern SCM scm_newline SCM_P ((SCM port)); -extern SCM scm_write_char SCM_P ((SCM chr, SCM port)); -extern SCM scm_printer_apply SCM_P ((SCM proc, SCM exp, SCM port, - scm_print_state *)); +extern SCM scm_print_options (SCM setting); +SCM scm_make_print_state (void); +void scm_free_print_state (SCM print_state); +extern void scm_intprint (long n, int radix, SCM port); +extern void scm_ipruk (char *hdr, SCM ptr, SCM port); +extern void scm_iprlist (char *hdr, SCM exp, int tlr, SCM port, scm_print_state *pstate); +extern void scm_prin1 (SCM exp, SCM port, int writingp); +extern void scm_iprin1 (SCM exp, SCM port, scm_print_state *pstate); +extern SCM scm_write (SCM obj, SCM port); +extern SCM scm_display (SCM obj, SCM port); +extern SCM scm_simple_format (SCM port, SCM message, SCM args); +extern SCM scm_newline (SCM port); +extern SCM scm_write_char (SCM chr, SCM port); +extern SCM scm_printer_apply (SCM proc, SCM exp, SCM port, + scm_print_state *); extern SCM scm_port_with_print_state (SCM port, SCM pstate); extern SCM scm_get_print_state (SCM port); -extern int scm_valid_oport_value_p SCM_P ((SCM val)); -extern void scm_init_print SCM_P ((void)); +extern int scm_valid_oport_value_p (SCM val); +extern void scm_init_print (void); #ifdef GUILE_DEBUG -extern SCM scm_current_pstate SCM_P ((void)); +extern SCM scm_current_pstate (void); #endif #endif /* PRINTH */ diff --git a/libguile/procs.h b/libguile/procs.h index c62e78497..3059bd350 100644 --- a/libguile/procs.h +++ b/libguile/procs.h @@ -169,31 +169,31 @@ extern int scm_subr_table_room; extern void scm_mark_subr_table (void); extern void scm_free_subr_entry (SCM subr); -extern SCM scm_make_subr SCM_P ((const char *name, int type, SCM (*fcn) ())); +extern SCM scm_make_subr (const char *name, int type, SCM (*fcn) ()); extern SCM scm_make_subr_with_generic (const char *name, int type, SCM (*fcn) (), SCM *gf); -extern SCM scm_make_subr_opt SCM_P ((const char *name, - int type, - SCM (*fcn) (), - int set)); -extern SCM scm_makcclo SCM_P ((SCM proc, long len)); -extern SCM scm_procedure_p SCM_P ((SCM obj)); -extern SCM scm_closure_p SCM_P ((SCM obj)); -extern SCM scm_thunk_p SCM_P ((SCM obj)); +extern SCM scm_make_subr_opt (const char *name, + int type, + SCM (*fcn) (), + int set); +extern SCM scm_makcclo (SCM proc, long len); +extern SCM scm_procedure_p (SCM obj); +extern SCM scm_closure_p (SCM obj); +extern SCM scm_thunk_p (SCM obj); extern int scm_subr_p (SCM obj); -extern SCM scm_procedure_documentation SCM_P ((SCM proc)); -extern SCM scm_procedure_with_setter_p SCM_P ((SCM obj)); -extern SCM scm_make_procedure_with_setter SCM_P ((SCM procedure, SCM setter)); -extern SCM scm_procedure SCM_P ((SCM proc)); -extern SCM scm_setter SCM_P ((SCM proc)); -extern void scm_init_iprocs SCM_P ((const scm_iproc *subra, int type)); +extern SCM scm_procedure_documentation (SCM proc); +extern SCM scm_procedure_with_setter_p (SCM obj); +extern SCM scm_make_procedure_with_setter (SCM procedure, SCM setter); +extern SCM scm_procedure (SCM proc); +extern SCM scm_setter (SCM proc); +extern void scm_init_iprocs (const scm_iproc *subra, int type); extern void scm_init_subr_table (void); -extern void scm_init_procs SCM_P ((void)); +extern void scm_init_procs (void); #ifdef GUILE_DEBUG -extern SCM scm_make_cclo SCM_P ((SCM proc, SCM len)); +extern SCM scm_make_cclo (SCM proc, SCM len); #endif /*GUILE_DEBUG*/ diff --git a/libguile/ramap.c b/libguile/ramap.c index 9eef95f5d..f6e417f8a 100644 --- a/libguile/ramap.c +++ b/libguile/ramap.c @@ -439,13 +439,13 @@ scm_array_fill_int (SCM ra, SCM fill, SCM ignore) SCM_VELTS (ra)[i] = fill; break; case scm_tc7_string: - SCM_ASRTGO (SCM_ICHRP (fill), badarg2); + SCM_ASRTGO (SCM_CHARP (fill), badarg2); for (i = base; n--; i += inc) - SCM_CHARS (ra)[i] = SCM_ICHR (fill); + SCM_CHARS (ra)[i] = SCM_CHAR (fill); break; case scm_tc7_byvect: - if (SCM_ICHRP (fill)) - fill = SCM_MAKINUM ((char) SCM_ICHR (fill)); + if (SCM_CHARP (fill)) + fill = SCM_MAKINUM ((char) SCM_CHAR (fill)); SCM_ASRTGO (SCM_INUMP (fill) && -128 <= SCM_INUM (fill) && SCM_INUM (fill) < 128, badarg2); diff --git a/libguile/ramap.h b/libguile/ramap.h index 38ee5752d..49df4acf2 100644 --- a/libguile/ramap.h +++ b/libguile/ramap.h @@ -48,27 +48,27 @@ -extern int scm_ra_matchp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ramapc SCM_P ((int (*cproc) (), SCM data, SCM ra0, SCM lra, - const char *what)); -extern int scm_array_fill_int SCM_P ((SCM ra, SCM fill, SCM ignore)); -extern SCM scm_array_fill_x SCM_P ((SCM ra, SCM fill)); -extern SCM scm_array_copy_x SCM_P ((SCM src, SCM dst)); -extern int scm_ra_eqp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_lessp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_leqp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_grp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_greqp SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_sum SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_difference SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_product SCM_P ((SCM ra0, SCM ras)); -extern int scm_ra_divide SCM_P ((SCM ra0, SCM ras)); -extern int scm_array_identity SCM_P ((SCM src, SCM dst)); -extern SCM scm_array_map_x SCM_P ((SCM ra0, SCM proc, SCM lra)); -extern SCM scm_array_for_each SCM_P ((SCM proc, SCM ra0, SCM lra)); -extern SCM scm_array_index_map_x SCM_P ((SCM ra, SCM proc)); -extern SCM scm_raequal SCM_P ((SCM ra0, SCM ra1)); -extern SCM scm_array_equal_p SCM_P ((SCM ra0, SCM ra1)); -extern void scm_init_ramap SCM_P ((void)); +extern int scm_ra_matchp (SCM ra0, SCM ras); +extern int scm_ramapc (int (*cproc) (), SCM data, SCM ra0, SCM lra, + const char *what); +extern int scm_array_fill_int (SCM ra, SCM fill, SCM ignore); +extern SCM scm_array_fill_x (SCM ra, SCM fill); +extern SCM scm_array_copy_x (SCM src, SCM dst); +extern int scm_ra_eqp (SCM ra0, SCM ras); +extern int scm_ra_lessp (SCM ra0, SCM ras); +extern int scm_ra_leqp (SCM ra0, SCM ras); +extern int scm_ra_grp (SCM ra0, SCM ras); +extern int scm_ra_greqp (SCM ra0, SCM ras); +extern int scm_ra_sum (SCM ra0, SCM ras); +extern int scm_ra_difference (SCM ra0, SCM ras); +extern int scm_ra_product (SCM ra0, SCM ras); +extern int scm_ra_divide (SCM ra0, SCM ras); +extern int scm_array_identity (SCM src, SCM dst); +extern SCM scm_array_map_x (SCM ra0, SCM proc, SCM lra); +extern SCM scm_array_for_each (SCM proc, SCM ra0, SCM lra); +extern SCM scm_array_index_map_x (SCM ra, SCM proc); +extern SCM scm_raequal (SCM ra0, SCM ra1); +extern SCM scm_array_equal_p (SCM ra0, SCM ra1); +extern void scm_init_ramap (void); #endif /* RAMAPH */ diff --git a/libguile/read.c b/libguile/read.c index c47e86f68..19e5ef6b9 100644 --- a/libguile/read.c +++ b/libguile/read.c @@ -371,17 +371,17 @@ tryagain_no_flush_ws: c = scm_getc (port); j = scm_read_token (c, tok_buf, port, 0); if (j == 1) - return SCM_MAKICHR (c); + return SCM_MAKE_CHAR (c); if (c >= '0' && c < '8') { p = scm_istr2int (SCM_CHARS (*tok_buf), (long) j, 8); if (SCM_NFALSEP (p)) - return SCM_MAKICHR (SCM_INUM (p)); + return SCM_MAKE_CHAR (SCM_INUM (p)); } for (c = 0; c < scm_n_charnames; c++) if (scm_charnames[c] && (scm_casei_streq (scm_charnames[c], SCM_CHARS (*tok_buf)))) - return SCM_MAKICHR (scm_charnums[c]); + return SCM_MAKE_CHAR (scm_charnums[c]); scm_wta (SCM_UNDEFINED, "unknown # object: #\\", SCM_CHARS (*tok_buf)); /* #:SYMBOL is a syntax for keywords supported in all contexts. */ @@ -402,7 +402,7 @@ tryagain_no_flush_ws: SCM got; got = scm_apply (sharp, - SCM_MAKICHR (c), + SCM_MAKE_CHAR (c), scm_acons (port, SCM_EOL, SCM_EOL)); if (SCM_UNSPECIFIED == got) goto unkshrp; @@ -415,7 +415,7 @@ tryagain_no_flush_ws: } unkshrp: scm_misc_error (s_scm_read, "Unknown # object: ~S", - scm_listify (SCM_MAKICHR (c), SCM_UNDEFINED)); + scm_listify (SCM_MAKE_CHAR (c), SCM_UNDEFINED)); } case '"': @@ -709,7 +709,7 @@ SCM_DEFINE (scm_read_hash_extend, "read-hash-extend", 2, 0, 0, SCM this; SCM prev; - SCM_VALIDATE_ICHR (1,chr); + SCM_VALIDATE_CHAR (1,chr); SCM_ASSERT (SCM_FALSEP (proc) || SCM_NIMP(proc), proc, SCM_ARG2, FUNC_NAME); @@ -768,7 +768,7 @@ scm_get_hash_procedure (int c) if (SCM_NULLP (rest)) return SCM_BOOL_F; - if (SCM_ICHR (SCM_CAAR (rest)) == c) + if (SCM_CHAR (SCM_CAAR (rest)) == c) return SCM_CDAR (rest); rest = SCM_CDR (rest); diff --git a/libguile/read.h b/libguile/read.h index 741041b63..847f080ce 100644 --- a/libguile/read.h +++ b/libguile/read.h @@ -77,16 +77,16 @@ extern scm_option scm_read_opts[]; -extern SCM scm_read_options SCM_P ((SCM setting)); -extern SCM scm_read SCM_P ((SCM port)); -extern char * scm_grow_tok_buf SCM_P ((SCM * tok_buf)); -extern int scm_flush_ws SCM_P ((SCM port, const char *eoferr)); -extern int scm_casei_streq SCM_P ((char * s1, char * s2)); -extern SCM scm_lreadr SCM_P ((SCM * tok_buf, SCM port, SCM *copy)); -extern scm_sizet scm_read_token SCM_P ((int ic, SCM * tok_buf, SCM port, int weird)); -extern SCM scm_lreadparen SCM_P ((SCM * tok_buf, SCM port, char *name, SCM *copy)); -extern SCM scm_lreadrecparen SCM_P ((SCM * tok_buf, SCM port, char *name, SCM *copy)); -extern SCM scm_read_hash_extend SCM_P ((SCM chr, SCM proc)); -extern void scm_init_read SCM_P ((void)); +extern SCM scm_read_options (SCM setting); +extern SCM scm_read (SCM port); +extern char * scm_grow_tok_buf (SCM * tok_buf); +extern int scm_flush_ws (SCM port, const char *eoferr); +extern int scm_casei_streq (char * s1, char * s2); +extern SCM scm_lreadr (SCM * tok_buf, SCM port, SCM *copy); +extern scm_sizet scm_read_token (int ic, SCM * tok_buf, SCM port, int weird); +extern SCM scm_lreadparen (SCM * tok_buf, SCM port, char *name, SCM *copy); +extern SCM scm_lreadrecparen (SCM * tok_buf, SCM port, char *name, SCM *copy); +extern SCM scm_read_hash_extend (SCM chr, SCM proc); +extern void scm_init_read (void); #endif /* READH */ diff --git a/libguile/regex-posix.h b/libguile/regex-posix.h index 172ed928c..fffbd249a 100644 --- a/libguile/regex-posix.h +++ b/libguile/regex-posix.h @@ -54,9 +54,9 @@ extern long scm_tc16_regex; #define SCM_RGX(X) ((regex_t *) SCM_CDR(X)) #define SCM_RGXP(X) (SCM_NIMP(X) && (SCM_CAR (X) == (SCM) scm_tc16_regex)) -extern SCM scm_make_regexp SCM_P ((SCM pat, SCM flags)); -SCM scm_regexp_p SCM_P ((SCM x)); -extern SCM scm_regexp_exec SCM_P ((SCM rx, SCM str, SCM start, SCM flags)); -extern void scm_init_regex_posix SCM_P ((void)); +extern SCM scm_make_regexp (SCM pat, SCM flags); +SCM scm_regexp_p (SCM x); +extern SCM scm_regexp_exec (SCM rx, SCM str, SCM start, SCM flags); +extern void scm_init_regex_posix (void); #endif diff --git a/libguile/root.h b/libguile/root.h index 12e2bbec1..c9fc4a751 100644 --- a/libguile/root.h +++ b/libguile/root.h @@ -157,16 +157,16 @@ extern struct scm_root_state *scm_root; -extern SCM scm_make_root SCM_P ((SCM parent)); -extern SCM scm_internal_cwdr SCM_P ((scm_catch_body_t body, - void *body_data, - scm_catch_handler_t handler, - void *handler_data, - SCM_STACKITEM *stack_start)); -extern SCM scm_call_with_dynamic_root SCM_P ((SCM thunk, SCM handler)); -extern SCM scm_dynamic_root SCM_P ((void)); -extern SCM scm_apply_with_dynamic_root SCM_P ((SCM proc, SCM a1, SCM args, SCM handler)); -extern SCM scm_call_catching_errors SCM_P ((SCM (*thunk)(), SCM (*err_filter)(), void * closure)); -extern void scm_init_root SCM_P ((void)); +extern SCM scm_make_root (SCM parent); +extern SCM scm_internal_cwdr (scm_catch_body_t body, + void *body_data, + scm_catch_handler_t handler, + void *handler_data, + SCM_STACKITEM *stack_start); +extern SCM scm_call_with_dynamic_root (SCM thunk, SCM handler); +extern SCM scm_dynamic_root (void); +extern SCM scm_apply_with_dynamic_root (SCM proc, SCM a1, SCM args, SCM handler); +extern SCM scm_call_catching_errors (SCM (*thunk)(), SCM (*err_filter)(), void * closure); +extern void scm_init_root (void); #endif /* ROOTH */ diff --git a/libguile/scm_validate.h b/libguile/scm_validate.h index d1df33394..92e8f9b38 100644 --- a/libguile/scm_validate.h +++ b/libguile/scm_validate.h @@ -1,4 +1,4 @@ -/* $Id: scm_validate.h,v 1.19 2000-01-17 19:44:01 gjb Exp $ */ +/* $Id: scm_validate.h,v 1.20 2000-03-02 20:54:43 gjb Exp $ */ /* Copyright (C) 1999 Free Software Foundation, Inc. * * This program is free software; you can redistribute it and/or modify @@ -100,11 +100,11 @@ do { SCM_ASSERT(SCM_BOOLP(flag), flag, pos, FUNC_NAME); \ cvar = (SCM_BOOL_T == flag)? 1: 0; } while (0) -#define SCM_VALIDATE_ICHR(pos,scm) SCM_MAKE_VALIDATE(pos,scm,ICHRP) +#define SCM_VALIDATE_CHAR(pos,scm) SCM_MAKE_VALIDATE(pos,scm,ICHRP) -#define SCM_VALIDATE_ICHR_COPY(pos,scm,cvar) \ - do { SCM_ASSERT(SCM_ICHRP(scm), scm, pos, FUNC_NAME); \ - cvar = SCM_ICHR(scm); } while (0) +#define SCM_VALIDATE_CHAR_COPY(pos,scm,cvar) \ + do { SCM_ASSERT(SCM_CHARP(scm), scm, pos, FUNC_NAME); \ + cvar = SCM_CHAR(scm); } while (0) #define SCM_VALIDATE_ROSTRING(pos,str) SCM_MAKE_VALIDATE(pos,str,ROSTRINGP) diff --git a/libguile/scmsigs.h b/libguile/scmsigs.h index 84eac8cf6..22ac5c054 100644 --- a/libguile/scmsigs.h +++ b/libguile/scmsigs.h @@ -48,12 +48,12 @@ extern SCM scm_sigaction (SCM signum, SCM handler, SCM flags); -extern SCM scm_restore_signals SCM_P ((void)); -extern SCM scm_alarm SCM_P ((SCM i)); -extern SCM scm_pause SCM_P ((void)); -extern SCM scm_sleep SCM_P ((SCM i)); -extern SCM scm_usleep SCM_P ((SCM i)); -extern SCM scm_raise SCM_P ((SCM sig)); -extern void scm_init_scmsigs SCM_P ((void)); +extern SCM scm_restore_signals (void); +extern SCM scm_alarm (SCM i); +extern SCM scm_pause (void); +extern SCM scm_sleep (SCM i); +extern SCM scm_usleep (SCM i); +extern SCM scm_raise (SCM sig); +extern void scm_init_scmsigs (void); #endif /* SCMSIGSH */ diff --git a/libguile/script.h b/libguile/script.h index a2895ec86..33509b813 100644 --- a/libguile/script.h +++ b/libguile/script.h @@ -46,17 +46,17 @@ #include "libguile/__scm.h" -extern char *scm_find_executable SCM_P ((const char *name)); -extern char *scm_find_impl_file SCM_P ((char *exec_path, - const char *generic_name, - const char *initname, - const char *sep)); -extern char **scm_get_meta_args SCM_P ((int argc, char **argv)); -extern int scm_count_argv SCM_P ((char **argv)); -extern void scm_shell_usage SCM_P ((int fatal, char *message)); -extern SCM scm_compile_shell_switches SCM_P ((int argc, char **argv)); -extern void scm_shell SCM_P ((int argc, char **argv)); +extern char *scm_find_executable (const char *name); +extern char *scm_find_impl_file (char *exec_path, + const char *generic_name, + const char *initname, + const char *sep); +extern char **scm_get_meta_args (int argc, char **argv); +extern int scm_count_argv (char **argv); +extern void scm_shell_usage (int fatal, char *message); +extern SCM scm_compile_shell_switches (int argc, char **argv); +extern void scm_shell (int argc, char **argv); extern char *scm_usage_name; -extern void scm_init_script SCM_P ((void)); +extern void scm_init_script (void); #endif /* SCRIPTH */ diff --git a/libguile/simpos.h b/libguile/simpos.h index f17c878f6..b3a5c949e 100644 --- a/libguile/simpos.h +++ b/libguile/simpos.h @@ -47,9 +47,9 @@ -extern SCM scm_system SCM_P ((SCM cmd)); -extern SCM scm_getenv SCM_P ((SCM nam)); -extern SCM scm_primitive_exit SCM_P ((SCM status)); -extern void scm_init_simpos SCM_P ((void)); +extern SCM scm_system (SCM cmd); +extern SCM scm_getenv (SCM nam); +extern SCM scm_primitive_exit (SCM status); +extern void scm_init_simpos (void); #endif /* SIMPOSH */ diff --git a/libguile/smob.h b/libguile/smob.h index 6c01acb7f..fd8ccc2b8 100644 --- a/libguile/smob.h +++ b/libguile/smob.h @@ -53,20 +53,20 @@ typedef struct scm_smob_descriptor { char *name; scm_sizet size; - SCM (*mark) SCM_P ((SCM)); - scm_sizet (*free) SCM_P ((SCM)); - int (*print) SCM_P ((SCM exp, SCM port, scm_print_state *pstate)); - SCM (*equalp) SCM_P ((SCM, SCM)); + SCM (*mark) (SCM); + scm_sizet (*free) (SCM); + int (*print) (SCM exp, SCM port, scm_print_state *pstate); + SCM (*equalp) (SCM, SCM); } scm_smob_descriptor; /* scm_smobfuns is the argument type for the obsolete function scm_newsmob */ typedef struct scm_smobfuns { - SCM (*mark) SCM_P ((SCM)); - scm_sizet (*free) SCM_P ((SCM)); - int (*print) SCM_P ((SCM exp, SCM port, scm_print_state *pstate)); - SCM (*equalp) SCM_P ((SCM, SCM)); + SCM (*mark) (SCM); + scm_sizet (*free) (SCM); + int (*print) (SCM exp, SCM port, scm_print_state *pstate); + SCM (*equalp) (SCM, SCM); } scm_smobfuns; @@ -97,9 +97,9 @@ extern scm_smob_descriptor *scm_smobs; -extern SCM scm_mark0 SCM_P ((SCM ptr)); -extern SCM scm_markcdr SCM_P ((SCM ptr)); -extern scm_sizet scm_free0 SCM_P ((SCM ptr)); +extern SCM scm_mark0 (SCM ptr); +extern SCM scm_markcdr (SCM ptr); +extern scm_sizet scm_free0 (SCM ptr); extern scm_sizet scm_smob_free (SCM obj); extern int scm_smob_print (SCM exp, SCM port, scm_print_state *pstate); diff --git a/libguile/srcprop.h b/libguile/srcprop.h index e6820d6c8..35afdf5bb 100644 --- a/libguile/srcprop.h +++ b/libguile/srcprop.h @@ -125,13 +125,13 @@ extern SCM scm_sym_breakpoint; -extern SCM scm_srcprops_to_plist SCM_P ((SCM obj)); -extern SCM scm_make_srcprops SCM_P ((int line, int col, SCM fname, SCM copy, SCM plist)); -extern SCM scm_source_property SCM_P ((SCM obj, SCM key)); -extern SCM scm_set_source_property_x SCM_P ((SCM obj, SCM key, SCM datum)); -extern SCM scm_source_properties SCM_P ((SCM obj)); -extern SCM scm_set_source_properties_x SCM_P ((SCM obj, SCM props)); -extern void scm_finish_srcprop SCM_P ((void)); -extern void scm_init_srcprop SCM_P ((void)); +extern SCM scm_srcprops_to_plist (SCM obj); +extern SCM scm_make_srcprops (int line, int col, SCM fname, SCM copy, SCM plist); +extern SCM scm_source_property (SCM obj, SCM key); +extern SCM scm_set_source_property_x (SCM obj, SCM key, SCM datum); +extern SCM scm_source_properties (SCM obj); +extern SCM scm_set_source_properties_x (SCM obj, SCM props); +extern void scm_finish_srcprop (void); +extern void scm_init_srcprop (void); #endif /* SRCPROPH */ diff --git a/libguile/stackchk.h b/libguile/stackchk.h index 777762526..44d3d9309 100644 --- a/libguile/stackchk.h +++ b/libguile/stackchk.h @@ -84,9 +84,9 @@ extern int scm_stack_checking_enabled_p; -extern void scm_report_stack_overflow SCM_P ((void)); -extern long scm_stack_size SCM_P ((SCM_STACKITEM *start)); -extern void scm_stack_report SCM_P ((void)); -extern void scm_init_stackchk SCM_P ((void)); +extern void scm_report_stack_overflow (void); +extern long scm_stack_size (SCM_STACKITEM *start); +extern void scm_stack_report (void); +extern void scm_init_stackchk (void); #endif /* STACKCHKH */ diff --git a/libguile/stacks.h b/libguile/stacks.h index 246e15183..d571584fe 100644 --- a/libguile/stacks.h +++ b/libguile/stacks.h @@ -115,26 +115,26 @@ extern SCM scm_stack_type; -SCM scm_stack_p SCM_P ((SCM obj)); -SCM scm_make_stack SCM_P ((SCM args)); -SCM scm_stack_id SCM_P ((SCM stack)); -SCM scm_stack_ref SCM_P ((SCM stack, SCM i)); -SCM scm_stack_length SCM_P ((SCM stack)); - -SCM scm_frame_p SCM_P ((SCM obj)); -SCM scm_last_stack_frame SCM_P ((SCM obj)); -SCM scm_frame_number SCM_P ((SCM frame)); -SCM scm_frame_source SCM_P ((SCM frame)); -SCM scm_frame_procedure SCM_P ((SCM frame)); -SCM scm_frame_arguments SCM_P ((SCM frame)); -SCM scm_frame_previous SCM_P ((SCM frame)); -SCM scm_frame_next SCM_P ((SCM frame)); -SCM scm_frame_real_p SCM_P ((SCM frame)); -SCM scm_frame_procedure_p SCM_P ((SCM frame)); -SCM scm_frame_evaluating_args_p SCM_P ((SCM frame)); -SCM scm_frame_overflow_p SCM_P ((SCM frame)); - - -void scm_init_stacks SCM_P ((void)); +SCM scm_stack_p (SCM obj); +SCM scm_make_stack (SCM args); +SCM scm_stack_id (SCM stack); +SCM scm_stack_ref (SCM stack, SCM i); +SCM scm_stack_length (SCM stack); + +SCM scm_frame_p (SCM obj); +SCM scm_last_stack_frame (SCM obj); +SCM scm_frame_number (SCM frame); +SCM scm_frame_source (SCM frame); +SCM scm_frame_procedure (SCM frame); +SCM scm_frame_arguments (SCM frame); +SCM scm_frame_previous (SCM frame); +SCM scm_frame_next (SCM frame); +SCM scm_frame_real_p (SCM frame); +SCM scm_frame_procedure_p (SCM frame); +SCM scm_frame_evaluating_args_p (SCM frame); +SCM scm_frame_overflow_p (SCM frame); + + +void scm_init_stacks (void); #endif /* STACKSH */ diff --git a/libguile/stime.h b/libguile/stime.h index 55e08cea4..bb57ab631 100644 --- a/libguile/stime.h +++ b/libguile/stime.h @@ -47,17 +47,17 @@ #include "libguile/__scm.h" -extern SCM scm_get_internal_real_time SCM_P ((void)); -extern SCM scm_get_internal_run_time SCM_P ((void)); -extern SCM scm_current_time SCM_P ((void)); +extern SCM scm_get_internal_real_time (void); +extern SCM scm_get_internal_run_time (void); +extern SCM scm_current_time (void); extern SCM scm_gettimeofday (void); extern SCM scm_localtime (SCM time, SCM zone); extern SCM scm_gmtime (SCM time); extern SCM scm_mktime (SCM sbd_time, SCM zone); extern SCM scm_tzset (void); extern SCM scm_times (void); -extern SCM scm_strftime SCM_P ((SCM format, SCM stime)); -extern SCM scm_strptime SCM_P ((SCM format, SCM string)); -extern void scm_init_stime SCM_P ((void)); +extern SCM scm_strftime (SCM format, SCM stime); +extern SCM scm_strptime (SCM format, SCM string); +extern void scm_init_stime (void); #endif /* STIMEH */ diff --git a/libguile/strings.c b/libguile/strings.c index 530073a40..b791f0175 100644 --- a/libguile/strings.c +++ b/libguile/strings.c @@ -60,15 +60,13 @@ SCM_DEFINE (scm_string_p, "string?", 1, 0, 0, "Returns #t iff OBJ is a string, else returns #f.") #define FUNC_NAME s_scm_string_p { - if (SCM_IMP (obj)) - return SCM_BOOL_F; return SCM_BOOL(SCM_STRINGP (obj)); } #undef FUNC_NAME SCM_DEFINE (scm_read_only_string_p, "read-only-string?", 1, 0, 0, (SCM x), - "Return true of OBJ can be read as a string,\n\n" + "Return true if OBJ can be read as a string,\n\n" "This illustrates the difference between @code{string?} and\n" "@code{read-only-string?}:\n\n" "@example\n" @@ -79,8 +77,6 @@ SCM_DEFINE (scm_read_only_string_p, "read-only-string?", 1, 0, 0, "@end example") #define FUNC_NAME s_scm_read_only_string_p { - if (SCM_IMP (x)) - return SCM_BOOL_F; return SCM_BOOL(SCM_ROSTRINGP (x)); } #undef FUNC_NAME @@ -108,8 +104,8 @@ SCM_DEFINE (scm_string, "string", 0, 0, 1, { SCM elt = SCM_CAR (chrs); - SCM_VALIDATE_ICHR (SCM_ARGn, elt); - *data++ = SCM_ICHR (elt); + SCM_VALIDATE_CHAR (SCM_ARGn, elt); + *data++ = SCM_CHAR (elt); chrs = SCM_CDR (chrs); } } @@ -227,10 +223,10 @@ SCM_DEFINE (scm_make_string, "make-string", 1, 1, 0, res = scm_makstr (i, 0); if (!SCM_UNBNDP (chr)) { - SCM_VALIDATE_ICHR (2,chr); + SCM_VALIDATE_CHAR (2,chr); { unsigned char *dst = SCM_UCHARS (res); - char c = SCM_ICHR (chr); + char c = SCM_CHAR (chr); memset (dst, c, i); } @@ -260,7 +256,7 @@ SCM_DEFINE (scm_string_ref, "string-ref", 2, 0, 0, SCM_VALIDATE_ROSTRING (1, str); SCM_VALIDATE_INUM_COPY (2, k, idx); SCM_ASSERT_RANGE (2, k, idx >= 0 && idx < SCM_ROLENGTH (str)); - return SCM_MAKICHR (SCM_ROUCHARS (str)[idx]); + return SCM_MAKE_CHAR (SCM_ROUCHARS (str)[idx]); } #undef FUNC_NAME @@ -272,8 +268,8 @@ SCM_DEFINE (scm_string_set_x, "string-set!", 3, 0, 0, { SCM_VALIDATE_RWSTRING (1,str); SCM_VALIDATE_INUM_RANGE (2,k,0,SCM_LENGTH(str)); - SCM_VALIDATE_ICHR (3,chr); - SCM_UCHARS (str)[SCM_INUM (k)] = SCM_ICHR (chr); + SCM_VALIDATE_CHAR (3,chr); + SCM_UCHARS (str)[SCM_INUM (k)] = SCM_CHAR (chr); return SCM_UNSPECIFIED; } #undef FUNC_NAME diff --git a/libguile/strop.c b/libguile/strop.c index b596f31d0..eee986aa4 100644 --- a/libguile/strop.c +++ b/libguile/strop.c @@ -61,7 +61,7 @@ scm_i_index (SCM *str, SCM chr, int direction, SCM sub_start, int ch; SCM_ASSERT (SCM_ROSTRINGP (*str), *str, SCM_ARG1, why); - SCM_ASSERT (SCM_ICHRP (chr), chr, SCM_ARG2, why); + SCM_ASSERT (SCM_CHARP (chr), chr, SCM_ARG2, why); if (sub_start == SCM_BOOL_F) sub_start = SCM_MAKINUM (0); @@ -84,7 +84,7 @@ scm_i_index (SCM *str, SCM chr, int direction, SCM sub_start, if (direction > 0) { p = (unsigned char *)SCM_ROCHARS (*str) + lower; - ch = SCM_ICHR (chr); + ch = SCM_CHAR (chr); for (x = SCM_INUM (sub_start); x < upper; ++x, ++p) if (*p == ch) @@ -93,7 +93,7 @@ scm_i_index (SCM *str, SCM chr, int direction, SCM sub_start, else { p = upper - 1 + (unsigned char *)SCM_ROCHARS (*str); - ch = SCM_ICHR (chr); + ch = SCM_CHAR (chr); for (x = upper - 1; x >= lower; --x, --p) if (*p == ch) return x; @@ -284,7 +284,7 @@ SCM_DEFINE (scm_substring_fill_x, "substring-fill!", 4, 0, 0, SCM_VALIDATE_STRING (1,str); SCM_VALIDATE_INUM_COPY (2,start,i); SCM_VALIDATE_INUM_COPY (3,end,e); - SCM_VALIDATE_ICHR_COPY (4,fill,c); + SCM_VALIDATE_CHAR_COPY (4,fill,c); SCM_ASSERT_RANGE (2,start,i <= SCM_LENGTH (str) && i >= 0); SCM_ASSERT_RANGE (3,end,e <= SCM_LENGTH (str) && e >= 0); while (i<e) SCM_CHARS (str)[i++] = c; @@ -327,7 +327,7 @@ SCM_DEFINE (scm_string_to_list, "string->list", 1, 0, 0, unsigned char *src; SCM_VALIDATE_ROSTRING (1,str); src = SCM_ROUCHARS (str); - for (i = SCM_ROLENGTH (str)-1;i >= 0;i--) res = scm_cons ((SCM)SCM_MAKICHR (src[i]), res); + for (i = SCM_ROLENGTH (str)-1;i >= 0;i--) res = scm_cons ((SCM)SCM_MAKE_CHAR (src[i]), res); return res; } #undef FUNC_NAME @@ -354,7 +354,7 @@ SCM_DEFINE (scm_string_fill_x, "string-fill!", 2, 0, 0, register char *dst, c; register long k; SCM_VALIDATE_STRING_COPY (1,str,dst); - SCM_VALIDATE_ICHR_COPY (2,chr,c); + SCM_VALIDATE_CHAR_COPY (2,chr,c); for (k = SCM_LENGTH (str)-1;k >= 0;k--) dst[k] = c; return SCM_UNSPECIFIED; } @@ -453,7 +453,7 @@ SCM_DEFINE (scm_string_capitalize_x, "string-capitalize!", 1, 0, 0, len = SCM_LENGTH(str); sz = SCM_CHARS(str); for(i=0; i<len; i++) { - if(SCM_NFALSEP(scm_char_alphabetic_p(SCM_MAKICHR(sz[i])))) { + if(SCM_NFALSEP(scm_char_alphabetic_p(SCM_MAKE_CHAR(sz[i])))) { if(!in_word) { sz[i] = scm_upcase(sz[i]); in_word = 1; diff --git a/libguile/strorder.h b/libguile/strorder.h index 71b94e9ab..7b45f8a94 100644 --- a/libguile/strorder.h +++ b/libguile/strorder.h @@ -53,16 +53,16 @@ -extern SCM scm_string_equal_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_ci_equal_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_less_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_leq_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_gr_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_geq_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_ci_less_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_ci_leq_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_ci_gr_p SCM_P ((SCM s1, SCM s2)); -extern SCM scm_string_ci_geq_p SCM_P ((SCM s1, SCM s2)); -extern void scm_init_strorder SCM_P ((void)); +extern SCM scm_string_equal_p (SCM s1, SCM s2); +extern SCM scm_string_ci_equal_p (SCM s1, SCM s2); +extern SCM scm_string_less_p (SCM s1, SCM s2); +extern SCM scm_string_leq_p (SCM s1, SCM s2); +extern SCM scm_string_gr_p (SCM s1, SCM s2); +extern SCM scm_string_geq_p (SCM s1, SCM s2); +extern SCM scm_string_ci_less_p (SCM s1, SCM s2); +extern SCM scm_string_ci_leq_p (SCM s1, SCM s2); +extern SCM scm_string_ci_gr_p (SCM s1, SCM s2); +extern SCM scm_string_ci_geq_p (SCM s1, SCM s2); +extern void scm_init_strorder (void); #endif /* STRORDERH */ diff --git a/libguile/strports.h b/libguile/strports.h index 302a88c66..5cdf910d7 100644 --- a/libguile/strports.h +++ b/libguile/strports.h @@ -48,14 +48,14 @@ -extern SCM scm_mkstrport SCM_P ((SCM pos, SCM str, long modes, const char * caller)); +extern SCM scm_mkstrport (SCM pos, SCM str, long modes, const char * caller); extern SCM scm_strport_to_string (SCM port); -extern SCM scm_call_with_output_string SCM_P ((SCM proc)); -extern SCM scm_strprint_obj SCM_P ((SCM obj)); -extern SCM scm_call_with_input_string SCM_P ((SCM str, SCM proc)); -extern SCM scm_read_0str SCM_P ((char *expr)); -extern SCM scm_eval_0str SCM_P ((const char *expr)); -extern SCM scm_eval_string SCM_P ((SCM string)); -extern void scm_init_strports SCM_P ((void)); +extern SCM scm_call_with_output_string (SCM proc); +extern SCM scm_strprint_obj (SCM obj); +extern SCM scm_call_with_input_string (SCM str, SCM proc); +extern SCM scm_read_0str (char *expr); +extern SCM scm_eval_0str (const char *expr); +extern SCM scm_eval_string (SCM string); +extern void scm_init_strports (void); #endif /* STRPORTSH */ diff --git a/libguile/struct.c b/libguile/struct.c index f70039fb0..23fec6948 100644 --- a/libguile/struct.c +++ b/libguile/struct.c @@ -103,13 +103,13 @@ SCM_DEFINE (scm_make_struct_layout, "make-struct-layout", 1, 0, 0, case 's': break; default: - SCM_ASSERT (0, SCM_MAKICHR (field_desc[x]) , "unrecognized field type", FUNC_NAME); + SCM_ASSERT (0, SCM_MAKE_CHAR (field_desc[x]) , "unrecognized field type", FUNC_NAME); } switch (field_desc[x + 1]) { case 'w': - SCM_ASSERT (field_desc[x] != 's', SCM_MAKICHR (field_desc[x + 1]), + SCM_ASSERT (field_desc[x] != 's', SCM_MAKE_CHAR (field_desc[x + 1]), "self fields not writable", FUNC_NAME); case 'r': @@ -118,15 +118,15 @@ SCM_DEFINE (scm_make_struct_layout, "make-struct-layout", 1, 0, 0, case 'R': case 'W': case 'O': - SCM_ASSERT (field_desc[x] != 's', SCM_MAKICHR (field_desc[x + 1]), + SCM_ASSERT (field_desc[x] != 's', SCM_MAKE_CHAR (field_desc[x + 1]), "self fields not allowed in tail array", FUNC_NAME); - SCM_ASSERT (x == len - 2, SCM_MAKICHR (field_desc[x + 1]), + SCM_ASSERT (x == len - 2, SCM_MAKE_CHAR (field_desc[x + 1]), "tail array field must be last field in layout", FUNC_NAME); break; default: - SCM_ASSERT (0, SCM_MAKICHR (field_desc[x]) , "unrecognized ref specification", FUNC_NAME); + SCM_ASSERT (0, SCM_MAKE_CHAR (field_desc[x]) , "unrecognized ref specification", FUNC_NAME); } #if 0 if (field_desc[x] == 'd') @@ -581,7 +581,7 @@ SCM_DEFINE (scm_struct_ref, "struct-ref", 2, 0, 0, default: - SCM_ASSERT (0, SCM_MAKICHR (field_type), "unrecognized field type", FUNC_NAME); + SCM_ASSERT (0, SCM_MAKE_CHAR (field_type), "unrecognized field type", FUNC_NAME); break; } @@ -651,11 +651,11 @@ SCM_DEFINE (scm_struct_set_x, "struct-set!", 3, 0, 0, break; case 's': - SCM_ASSERT (0, SCM_MAKICHR (field_type), "self fields immutable", FUNC_NAME); + SCM_ASSERT (0, SCM_MAKE_CHAR (field_type), "self fields immutable", FUNC_NAME); break; default: - SCM_ASSERT (0, SCM_MAKICHR (field_type), "unrecognized field type", FUNC_NAME); + SCM_ASSERT (0, SCM_MAKE_CHAR (field_type), "unrecognized field type", FUNC_NAME); break; } diff --git a/libguile/struct.h b/libguile/struct.h index bfd894b65..38b7c9235 100644 --- a/libguile/struct.h +++ b/libguile/struct.h @@ -102,21 +102,21 @@ extern scm_sizet scm_struct_free_0 (SCM *vtable, SCM *data); extern scm_sizet scm_struct_free_light (SCM *vtable, SCM *data); extern scm_sizet scm_struct_free_standard (SCM *vtable, SCM *data); extern scm_sizet scm_struct_free_entity (SCM *vtable, SCM *data); -extern void scm_struct_init SCM_P ((SCM handle, int tail_elts, SCM inits)); -extern SCM scm_make_struct_layout SCM_P ((SCM fields)); -extern SCM scm_struct_p SCM_P ((SCM x)); -extern SCM scm_struct_vtable_p SCM_P ((SCM x)); -extern SCM scm_make_struct SCM_P ((SCM vtable, SCM tail_array_size, SCM init)); -extern SCM scm_make_vtable_vtable SCM_P ((SCM extra_fields, SCM tail_array_size, SCM init)); -extern SCM scm_struct_ref SCM_P ((SCM handle, SCM pos)); -extern SCM scm_struct_set_x SCM_P ((SCM handle, SCM pos, SCM val)); -extern SCM scm_struct_vtable SCM_P ((SCM handle)); -extern SCM scm_struct_vtable_tag SCM_P ((SCM handle)); -extern unsigned int scm_struct_ihashq SCM_P ((SCM obj, unsigned int n)); -extern SCM scm_struct_create_handle SCM_P ((SCM obj)); -extern SCM scm_struct_vtable_name SCM_P ((SCM vtable)); -extern SCM scm_set_struct_vtable_name_x SCM_P ((SCM vtable, SCM name)); -extern void scm_print_struct SCM_P ((SCM exp, SCM port, scm_print_state *)); -extern void scm_init_struct SCM_P ((void)); +extern void scm_struct_init (SCM handle, int tail_elts, SCM inits); +extern SCM scm_make_struct_layout (SCM fields); +extern SCM scm_struct_p (SCM x); +extern SCM scm_struct_vtable_p (SCM x); +extern SCM scm_make_struct (SCM vtable, SCM tail_array_size, SCM init); +extern SCM scm_make_vtable_vtable (SCM extra_fields, SCM tail_array_size, SCM init); +extern SCM scm_struct_ref (SCM handle, SCM pos); +extern SCM scm_struct_set_x (SCM handle, SCM pos, SCM val); +extern SCM scm_struct_vtable (SCM handle); +extern SCM scm_struct_vtable_tag (SCM handle); +extern unsigned int scm_struct_ihashq (SCM obj, unsigned int n); +extern SCM scm_struct_create_handle (SCM obj); +extern SCM scm_struct_vtable_name (SCM vtable); +extern SCM scm_set_struct_vtable_name_x (SCM vtable, SCM name); +extern void scm_print_struct (SCM exp, SCM port, scm_print_state *); +extern void scm_init_struct (void); #endif /* STRUCTH */ diff --git a/libguile/symbols.h b/libguile/symbols.h index cc441c34b..5495d61e4 100644 --- a/libguile/symbols.h +++ b/libguile/symbols.h @@ -109,37 +109,37 @@ extern int scm_symhash_dim; -extern unsigned long scm_strhash SCM_P ((unsigned char *str, scm_sizet len, unsigned long n)); -extern SCM scm_sym2vcell SCM_P ((SCM sym, SCM thunk, SCM definep)); -extern SCM scm_sym2ovcell_soft SCM_P ((SCM sym, SCM obarray)); -extern SCM scm_sym2ovcell SCM_P ((SCM sym, SCM obarray)); -extern SCM scm_intern_obarray_soft SCM_P ((const char *name, scm_sizet len, SCM obarray, int softness)); -extern SCM scm_intern_obarray SCM_P ((const char *name, scm_sizet len, SCM obarray)); -extern SCM scm_intern SCM_P ((const char *name, scm_sizet len)); -extern SCM scm_intern0 SCM_P ((const char * name)); -extern SCM scm_sysintern SCM_P ((const char *name, SCM val)); -extern SCM scm_sysintern0 SCM_P ((const char *name)); -extern SCM scm_sysintern0_no_module_lookup SCM_P ((const char *name)); -extern SCM scm_symbol_value0 SCM_P ((const char *name)); -extern SCM scm_symbol_p SCM_P ((SCM x)); -extern SCM scm_symbol_to_string SCM_P ((SCM s)); -extern SCM scm_string_to_symbol SCM_P ((SCM s)); -extern SCM scm_string_to_obarray_symbol SCM_P ((SCM o, SCM s, SCM softp)); -extern SCM scm_intern_symbol SCM_P ((SCM o, SCM s)); -extern SCM scm_unintern_symbol SCM_P ((SCM o, SCM s)); -extern SCM scm_symbol_binding SCM_P ((SCM o, SCM s)); -extern SCM scm_symbol_interned_p SCM_P ((SCM o, SCM s)); -extern SCM scm_symbol_bound_p SCM_P ((SCM o, SCM s)); -extern SCM scm_symbol_set_x SCM_P ((SCM o, SCM s, SCM v)); -extern SCM scm_symbol_fref SCM_P ((SCM s)); -extern SCM scm_symbol_pref SCM_P ((SCM s)); -extern SCM scm_symbol_fset_x SCM_P ((SCM s, SCM val)); -extern SCM scm_symbol_pset_x SCM_P ((SCM s, SCM val)); -extern SCM scm_symbol_hash SCM_P ((SCM s)); -extern SCM scm_builtin_bindings SCM_P ((void)); -extern SCM scm_builtin_weak_bindings SCM_P ((void)); -extern SCM scm_gensym SCM_P ((SCM name, SCM obarray)); -extern void scm_init_symbols SCM_P ((void)); +extern unsigned long scm_strhash (unsigned char *str, scm_sizet len, unsigned long n); +extern SCM scm_sym2vcell (SCM sym, SCM thunk, SCM definep); +extern SCM scm_sym2ovcell_soft (SCM sym, SCM obarray); +extern SCM scm_sym2ovcell (SCM sym, SCM obarray); +extern SCM scm_intern_obarray_soft (const char *name, scm_sizet len, SCM obarray, int softness); +extern SCM scm_intern_obarray (const char *name, scm_sizet len, SCM obarray); +extern SCM scm_intern (const char *name, scm_sizet len); +extern SCM scm_intern0 (const char * name); +extern SCM scm_sysintern (const char *name, SCM val); +extern SCM scm_sysintern0 (const char *name); +extern SCM scm_sysintern0_no_module_lookup (const char *name); +extern SCM scm_symbol_value0 (const char *name); +extern SCM scm_symbol_p (SCM x); +extern SCM scm_symbol_to_string (SCM s); +extern SCM scm_string_to_symbol (SCM s); +extern SCM scm_string_to_obarray_symbol (SCM o, SCM s, SCM softp); +extern SCM scm_intern_symbol (SCM o, SCM s); +extern SCM scm_unintern_symbol (SCM o, SCM s); +extern SCM scm_symbol_binding (SCM o, SCM s); +extern SCM scm_symbol_interned_p (SCM o, SCM s); +extern SCM scm_symbol_bound_p (SCM o, SCM s); +extern SCM scm_symbol_set_x (SCM o, SCM s, SCM v); +extern SCM scm_symbol_fref (SCM s); +extern SCM scm_symbol_pref (SCM s); +extern SCM scm_symbol_fset_x (SCM s, SCM val); +extern SCM scm_symbol_pset_x (SCM s, SCM val); +extern SCM scm_symbol_hash (SCM s); +extern SCM scm_builtin_bindings (void); +extern SCM scm_builtin_weak_bindings (void); +extern SCM scm_gensym (SCM name, SCM obarray); +extern void scm_init_symbols (void); extern int scm_can_use_top_level_lookup_closure_var; diff --git a/libguile/tag.c b/libguile/tag.c index 154d4283b..24e6b1802 100644 --- a/libguile/tag.c +++ b/libguile/tag.c @@ -101,7 +101,7 @@ SCM_DEFINE (scm_tag, "tag", 1, 0, 0, return SCM_CDR (scm_utag_immediate_integer) ; case scm_tc3_imm24: - if (SCM_ICHRP (x)) + if (SCM_CHARP (x)) return SCM_CDR (scm_utag_immediate_char) ; else { diff --git a/libguile/tag.h b/libguile/tag.h index 9beaef8dd..e42730c6e 100644 --- a/libguile/tag.h +++ b/libguile/tag.h @@ -52,7 +52,7 @@ -extern SCM scm_tag SCM_P ((SCM x)); -extern void scm_init_tag SCM_P ((void)); +extern SCM scm_tag (SCM x); +extern void scm_init_tag (void); #endif /* TAGH */ diff --git a/libguile/threads.h b/libguile/threads.h index 53255048d..b25c2f3ae 100644 --- a/libguile/threads.h +++ b/libguile/threads.h @@ -66,15 +66,15 @@ extern long scm_tc16_condvar; #define SCM_CONDVAR_DATA(obj) ((void *) SCM_CDR (obj)) /* Initialize implementation specific details of the threads support */ -void scm_threads_init SCM_P ((SCM_STACKITEM *)); -void scm_threads_mark_stacks SCM_P ((void)); -void scm_init_threads SCM_P ((SCM_STACKITEM *)); +void scm_threads_init (SCM_STACKITEM *); +void scm_threads_mark_stacks (void); +void scm_init_threads (SCM_STACKITEM *); /* */ -SCM scm_threads_make_mutex SCM_P ((void)); -SCM scm_threads_lock_mutex SCM_P ((SCM)); -SCM scm_threads_unlock_mutex SCM_P ((SCM)); -SCM scm_threads_monitor SCM_P ((void)); +SCM scm_threads_make_mutex (void); +SCM scm_threads_lock_mutex (SCM); +SCM scm_threads_unlock_mutex (SCM); +SCM scm_threads_monitor (void); SCM scm_spawn_thread (scm_catch_body_t body, void *body_data, scm_catch_handler_t handler, void *handler_data); diff --git a/libguile/throw.h b/libguile/throw.h index 9485686d1..e0ef204bb 100644 --- a/libguile/throw.h +++ b/libguile/throw.h @@ -48,27 +48,27 @@ -typedef SCM (*scm_catch_body_t) SCM_P ((void *data)); -typedef SCM (*scm_catch_handler_t) SCM_P ((void *data, - SCM tag, SCM throw_args)); +typedef SCM (*scm_catch_body_t) (void *data); +typedef SCM (*scm_catch_handler_t) (void *data, + SCM tag, SCM throw_args); -extern SCM scm_internal_catch SCM_P ((SCM tag, - scm_catch_body_t body, - void *body_data, - scm_catch_handler_t handler, - void *handler_data)); +extern SCM scm_internal_catch (SCM tag, + scm_catch_body_t body, + void *body_data, + scm_catch_handler_t handler, + void *handler_data); -extern SCM scm_internal_lazy_catch SCM_P ((SCM tag, - scm_catch_body_t body, - void *body_data, - scm_catch_handler_t handler, - void *handler_data)); +extern SCM scm_internal_lazy_catch (SCM tag, + scm_catch_body_t body, + void *body_data, + scm_catch_handler_t handler, + void *handler_data); -extern SCM scm_internal_stack_catch SCM_P ((SCM tag, - scm_catch_body_t body, - void *body_data, - scm_catch_handler_t handler, - void *handler_data)); +extern SCM scm_internal_stack_catch (SCM tag, + scm_catch_body_t body, + void *body_data, + scm_catch_handler_t handler, + void *handler_data); /* The first argument to scm_body_thunk should be a pointer to one of these. See the implementation of catch in throw.c. */ @@ -84,20 +84,20 @@ struct scm_body_thunk_data SCM body_proc; }; -extern SCM scm_body_thunk SCM_P ((void *)); +extern SCM scm_body_thunk (void *); -extern SCM scm_handle_by_proc SCM_P ((void *, SCM, SCM)); -extern SCM scm_handle_by_proc_catching_all SCM_P ((void *, SCM, SCM)); -extern SCM scm_handle_by_message SCM_P ((void *, SCM, SCM)); -extern SCM scm_handle_by_message_noexit SCM_P ((void *, SCM, SCM)); -extern SCM scm_handle_by_throw SCM_P ((void *, SCM, SCM)); -extern int scm_exit_status SCM_P ((SCM args)); +extern SCM scm_handle_by_proc (void *, SCM, SCM); +extern SCM scm_handle_by_proc_catching_all (void *, SCM, SCM); +extern SCM scm_handle_by_message (void *, SCM, SCM); +extern SCM scm_handle_by_message_noexit (void *, SCM, SCM); +extern SCM scm_handle_by_throw (void *, SCM, SCM); +extern int scm_exit_status (SCM args); -extern SCM scm_catch SCM_P ((SCM tag, SCM thunk, SCM handler)); -extern SCM scm_lazy_catch SCM_P ((SCM tag, SCM thunk, SCM handler)); -extern SCM scm_ithrow SCM_P ((SCM key, SCM args, int noreturn)); +extern SCM scm_catch (SCM tag, SCM thunk, SCM handler); +extern SCM scm_lazy_catch (SCM tag, SCM thunk, SCM handler); +extern SCM scm_ithrow (SCM key, SCM args, int noreturn); -extern SCM scm_throw SCM_P ((SCM key, SCM args)); -extern void scm_init_throw SCM_P ((void)); +extern SCM scm_throw (SCM key, SCM args); +extern void scm_init_throw (void); #endif /* THROWH */ diff --git a/libguile/unif.c b/libguile/unif.c index 9948bed28..4a96198ea 100644 --- a/libguile/unif.c +++ b/libguile/unif.c @@ -161,12 +161,12 @@ scm_make_uve (long k, SCM prot) i = sizeof (long) * ((k + SCM_LONG_BIT - 1) / SCM_LONG_BIT); type = scm_tc7_bvect; } - else if (SCM_ICHRP (prot) && (prot == SCM_MAKICHR ('\0'))) + else if (SCM_CHARP (prot) && (prot == SCM_MAKE_CHAR ('\0'))) { i = sizeof (char) * k; type = scm_tc7_byvect; } - else if (SCM_ICHRP (prot)) + else if (SCM_CHARP (prot)) { i = sizeof (char) * k; type = scm_tc7_string; @@ -295,9 +295,9 @@ loop: case scm_tc7_bvect: return nprot || SCM_BOOL(SCM_BOOL_T==prot); case scm_tc7_string: - return nprot || SCM_BOOL(SCM_ICHRP(prot) && (prot != SCM_MAKICHR('\0'))); + return nprot || SCM_BOOL(SCM_CHARP(prot) && (prot != SCM_MAKE_CHAR('\0'))); case scm_tc7_byvect: - return nprot || SCM_BOOL(prot == SCM_MAKICHR('\0')); + return nprot || SCM_BOOL(prot == SCM_MAKE_CHAR('\0')); case scm_tc7_uvect: return nprot || SCM_BOOL(SCM_INUMP(prot) && SCM_INUM(prot)>0); case scm_tc7_ivect: @@ -923,7 +923,7 @@ SCM_DEFINE (scm_enclose_array, "enclose-array", 0, 0, 1, break; } noutr = ndim - ninr; - axv = scm_make_string (SCM_MAKINUM (ndim), SCM_MAKICHR (0)); + axv = scm_make_string (SCM_MAKINUM (ndim), SCM_MAKE_CHAR (0)); SCM_ASSERT (0 <= noutr && 0 <= ninr, scm_makfrom0str (FUNC_NAME), SCM_WNA, NULL); res = scm_make_ra (noutr); @@ -1101,7 +1101,7 @@ SCM_DEFINE (scm_uniform_vector_ref, "uniform-vector-ref", 2, 0, 0, else return SCM_BOOL_F; case scm_tc7_string: - return SCM_MAKICHR (SCM_UCHARS (v)[pos]); + return SCM_MAKE_CHAR (SCM_UCHARS (v)[pos]); case scm_tc7_byvect: return SCM_MAKINUM (((char *)SCM_CHARS (v))[pos]); # ifdef SCM_INUMS_ONLY @@ -1156,7 +1156,7 @@ scm_cvref (SCM v, scm_sizet pos, SCM last) else return SCM_BOOL_F; case scm_tc7_string: - return SCM_MAKICHR (SCM_UCHARS (v)[pos]); + return SCM_MAKE_CHAR (SCM_UCHARS (v)[pos]); case scm_tc7_byvect: return SCM_MAKINUM (((char *)SCM_CHARS (v))[pos]); # ifdef SCM_INUMS_ONLY @@ -1277,12 +1277,12 @@ SCM_DEFINE (scm_array_set_x, "array-set!", 2, 0, 1, badobj:SCM_WTA (2,obj); break; case scm_tc7_string: - SCM_ASRTGO (SCM_ICHRP (obj), badobj); - SCM_UCHARS (v)[pos] = SCM_ICHR (obj); + SCM_ASRTGO (SCM_CHARP (obj), badobj); + SCM_UCHARS (v)[pos] = SCM_CHAR (obj); break; case scm_tc7_byvect: - if (SCM_ICHRP (obj)) - obj = SCM_MAKINUM ((char) SCM_ICHR (obj)); + if (SCM_CHARP (obj)) + obj = SCM_MAKINUM ((char) SCM_CHAR (obj)); SCM_ASRTGO (SCM_INUMP (obj), badobj); ((char *)SCM_CHARS (v))[pos] = SCM_INUM (obj); break; @@ -2289,12 +2289,12 @@ tail: break; case scm_tc7_string: if (n-- > 0) - scm_iprin1 (SCM_MAKICHR (SCM_UCHARS (ra)[j]), port, pstate); + scm_iprin1 (SCM_MAKE_CHAR (SCM_UCHARS (ra)[j]), port, pstate); if (SCM_WRITINGP (pstate)) for (j += inc; n-- > 0; j += inc) { scm_putc (' ', port); - scm_iprin1 (SCM_MAKICHR (SCM_UCHARS (ra)[j]), port, pstate); + scm_iprin1 (SCM_MAKE_CHAR (SCM_UCHARS (ra)[j]), port, pstate); } else for (j += inc; n-- > 0; j += inc) @@ -2524,9 +2524,9 @@ loop: case scm_tc7_bvect: return SCM_BOOL_T; case scm_tc7_string: - return SCM_MAKICHR ('a'); + return SCM_MAKE_CHAR ('a'); case scm_tc7_byvect: - return SCM_MAKICHR ('\0'); + return SCM_MAKE_CHAR ('\0'); case scm_tc7_uvect: return SCM_MAKINUM (1L); case scm_tc7_ivect: diff --git a/libguile/variable.h b/libguile/variable.h index 21cc482c3..516b44e13 100644 --- a/libguile/variable.h +++ b/libguile/variable.h @@ -62,13 +62,13 @@ extern int scm_tc16_variable; -extern SCM scm_make_variable SCM_P ((SCM init, SCM name_hint)); -extern SCM scm_make_undefined_variable SCM_P ((SCM name_hint)); -extern SCM scm_variable_p SCM_P ((SCM obj)); -extern SCM scm_variable_ref SCM_P ((SCM var)); -extern SCM scm_variable_set_x SCM_P ((SCM var, SCM val)); -extern SCM scm_builtin_variable SCM_P ((SCM name)); -extern SCM scm_variable_bound_p SCM_P ((SCM var)); -extern void scm_init_variable SCM_P ((void)); +extern SCM scm_make_variable (SCM init, SCM name_hint); +extern SCM scm_make_undefined_variable (SCM name_hint); +extern SCM scm_variable_p (SCM obj); +extern SCM scm_variable_ref (SCM var); +extern SCM scm_variable_set_x (SCM var, SCM val); +extern SCM scm_builtin_variable (SCM name); +extern SCM scm_variable_bound_p (SCM var); +extern void scm_init_variable (void); #endif /* VARIABLEH */ diff --git a/libguile/vectors.h b/libguile/vectors.h index 75a91cf6d..df4902c33 100644 --- a/libguile/vectors.h +++ b/libguile/vectors.h @@ -58,20 +58,20 @@ -extern SCM scm_vector_set_length_x SCM_P ((SCM vect, SCM len)); -extern SCM scm_vector_p SCM_P ((SCM x)); -extern SCM scm_vector_length SCM_P ((SCM v)); -extern SCM scm_vector SCM_P ((SCM l)); -extern SCM scm_vector_ref SCM_P ((SCM v, SCM k)); -extern SCM scm_vector_set_x SCM_P ((SCM v, SCM k, SCM obj)); -extern SCM scm_make_vector SCM_P ((SCM k, SCM fill)); -extern SCM scm_vector_to_list SCM_P ((SCM v)); -extern SCM scm_vector_fill_x SCM_P ((SCM v, SCM fill_x)); -extern SCM scm_vector_equal_p SCM_P ((SCM x, SCM y)); -extern SCM scm_vector_move_left_x SCM_P ((SCM vec1, SCM start1, SCM end1, SCM - vec2, SCM start2)); -extern SCM scm_vector_move_right_x SCM_P ((SCM vec1, SCM start1, SCM end1, SCM - vec2, SCM start2)); -extern void scm_init_vectors SCM_P ((void)); +extern SCM scm_vector_set_length_x (SCM vect, SCM len); +extern SCM scm_vector_p (SCM x); +extern SCM scm_vector_length (SCM v); +extern SCM scm_vector (SCM l); +extern SCM scm_vector_ref (SCM v, SCM k); +extern SCM scm_vector_set_x (SCM v, SCM k, SCM obj); +extern SCM scm_make_vector (SCM k, SCM fill); +extern SCM scm_vector_to_list (SCM v); +extern SCM scm_vector_fill_x (SCM v, SCM fill_x); +extern SCM scm_vector_equal_p (SCM x, SCM y); +extern SCM scm_vector_move_left_x (SCM vec1, SCM start1, SCM end1, + SCM vec2, SCM start2); +extern SCM scm_vector_move_right_x (SCM vec1, SCM start1, SCM end1, + SCM vec2, SCM start2); +extern void scm_init_vectors (void); #endif /* VECTORSH */ diff --git a/libguile/version.h b/libguile/version.h index 4519b1e5c..147677204 100644 --- a/libguile/version.h +++ b/libguile/version.h @@ -48,9 +48,9 @@ -extern SCM scm_major_version SCM_P ((void)); -extern SCM scm_minor_version SCM_P ((void)); -extern SCM scm_version SCM_P ((void)); -extern void scm_init_version SCM_P ((void)); +extern SCM scm_major_version (void); +extern SCM scm_minor_version (void); +extern SCM scm_version (void); +extern void scm_init_version (void); #endif /* VERSIONH */ diff --git a/libguile/vports.c b/libguile/vports.c index 89cc35cd7..00056c0f6 100644 --- a/libguile/vports.c +++ b/libguile/vports.c @@ -73,7 +73,7 @@ sf_flush (SCM port) if (pt->write_pos > pt->write_buf) { /* write the byte. */ - scm_apply (SCM_VELTS (stream)[0], SCM_MAKICHR (*pt->write_buf), + scm_apply (SCM_VELTS (stream)[0], SCM_MAKE_CHAR (*pt->write_buf), scm_listofnull); pt->write_pos = pt->write_buf; @@ -111,11 +111,11 @@ sf_fill_input (SCM port) ans = scm_apply (SCM_VELTS (p)[3], SCM_EOL, SCM_EOL); /* get char. */ if (SCM_FALSEP (ans) || SCM_EOF_OBJECT_P (ans)) return EOF; - SCM_ASSERT (SCM_ICHRP (ans), ans, SCM_ARG1, "sf_fill_input"); + SCM_ASSERT (SCM_CHARP (ans), ans, SCM_ARG1, "sf_fill_input"); { scm_port *pt = SCM_PTAB_ENTRY (port); - *pt->read_buf = SCM_ICHR (ans); + *pt->read_buf = SCM_CHAR (ans); pt->read_pos = pt->read_buf; pt->read_end = pt->read_buf + 1; return *pt->read_buf; diff --git a/libguile/vports.h b/libguile/vports.h index 92dc24620..0e8aad183 100644 --- a/libguile/vports.h +++ b/libguile/vports.h @@ -48,7 +48,7 @@ -extern SCM scm_make_soft_port SCM_P ((SCM pv, SCM modes)); -extern void scm_init_vports SCM_P ((void)); +extern SCM scm_make_soft_port (SCM pv, SCM modes); +extern void scm_init_vports (void); #endif /* VPORTSH */ diff --git a/libguile/weaks.h b/libguile/weaks.h index c31b66f65..e6c4bfa81 100644 --- a/libguile/weaks.h +++ b/libguile/weaks.h @@ -61,15 +61,15 @@ -extern SCM scm_make_weak_vector SCM_P ((SCM k, SCM fill)); -extern SCM scm_weak_vector SCM_P ((SCM l)); -extern SCM scm_weak_vector_p SCM_P ((SCM x)); -extern SCM scm_make_weak_key_hash_table SCM_P ((SCM k)); -extern SCM scm_make_weak_value_hash_table SCM_P ((SCM k)); -extern SCM scm_make_doubly_weak_hash_table SCM_P ((SCM k)); -extern SCM scm_weak_key_hash_table_p SCM_P ((SCM x)); -extern SCM scm_weak_value_hash_table_p SCM_P ((SCM x)); -extern SCM scm_doubly_weak_hash_table_p SCM_P ((SCM x)); -extern void scm_init_weaks SCM_P ((void)); +extern SCM scm_make_weak_vector (SCM k, SCM fill); +extern SCM scm_weak_vector (SCM l); +extern SCM scm_weak_vector_p (SCM x); +extern SCM scm_make_weak_key_hash_table (SCM k); +extern SCM scm_make_weak_value_hash_table (SCM k); +extern SCM scm_make_doubly_weak_hash_table (SCM k); +extern SCM scm_weak_key_hash_table_p (SCM x); +extern SCM scm_weak_value_hash_table_p (SCM x); +extern SCM scm_doubly_weak_hash_table_p (SCM x); +extern void scm_init_weaks (void); #endif /* WEAKSH */ |