diff --git a/libguile/ChangeLog b/libguile/ChangeLog index e972110a6..a7b2a97a3 100644 --- a/libguile/ChangeLog +++ b/libguile/ChangeLog @@ -1,3 +1,19 @@ +Thu Feb 6 03:10:32 1997 Gary Houston + + * strop.c (scm_string_upcase_x, scm_string_downcase_x): moved from + unif.c. + strop.h: move prototypes too. + +Wed Feb 5 08:33:00 1997 Gary Houston + + * posix.c (scm_init_posix): don't intern EINTR since it's now done + elsewhere. + + * ioext.c (scm_init_ioext): don't intern stat macros, S_IRUSR + etc. I deleted them from filesys.c long ago, but didn't + notice they were here too (although ineffective since + sys/stat.h wasn't included). + Tue Feb 4 18:17:50 1997 Tom Tromey * eval.c: Don't define alloca in GCC case. gcc will automatically diff --git a/libguile/ioext.c b/libguile/ioext.c index e5e571c5f..694dd5739 100644 --- a/libguile/ioext.c +++ b/libguile/ioext.c @@ -473,80 +473,6 @@ scm_init_ioext () scm_sysintern ("SEEK_CUR", SCM_MAKINUM (SEEK_CUR)); scm_sysintern ("SEEK_END", SCM_MAKINUM (SEEK_END)); - /* File type/permission bits. */ -#ifdef S_IRUSR - scm_sysintern ("S_IRUSR", SCM_MAKINUM (S_IRUSR)); -#endif -#ifdef S_IWUSR - scm_sysintern ("S_IWUSR", SCM_MAKINUM (S_IWUSR)); -#endif -#ifdef S_IXUSR - scm_sysintern ("S_IXUSR", SCM_MAKINUM (S_IXUSR)); -#endif -#ifdef S_IRWXU - scm_sysintern ("S_IRWXU", SCM_MAKINUM (S_IRWXU)); -#endif - -#ifdef S_IRGRP - scm_sysintern ("S_IRGRP", SCM_MAKINUM (S_IRGRP)); -#endif -#ifdef S_IWGRP - scm_sysintern ("S_IWGRP", SCM_MAKINUM (S_IWGRP)); -#endif -#ifdef S_IXGRP - scm_sysintern ("S_IXGRP", SCM_MAKINUM (S_IXGRP)); -#endif -#ifdef S_IRWXG - scm_sysintern ("S_IRWXG", SCM_MAKINUM (S_IRWXG)); -#endif - -#ifdef S_IROTH - scm_sysintern ("S_IROTH", SCM_MAKINUM (S_IROTH)); -#endif -#ifdef S_IWOTH - scm_sysintern ("S_IWOTH", SCM_MAKINUM (S_IWOTH)); -#endif -#ifdef S_IXOTH - scm_sysintern ("S_IXOTH", SCM_MAKINUM (S_IXOTH)); -#endif -#ifdef S_IRWXO - scm_sysintern ("S_IRWXO", SCM_MAKINUM (S_IRWXO)); -#endif - -#ifdef S_ISUID - scm_sysintern ("S_ISUID", SCM_MAKINUM (S_ISUID)); -#endif -#ifdef S_ISGID - scm_sysintern ("S_ISGID", SCM_MAKINUM (S_ISGID)); -#endif -#ifdef S_ISVTX - scm_sysintern ("S_ISVTX", SCM_MAKINUM (S_ISVTX)); -#endif - -#ifdef S_IFMT - scm_sysintern ("S_IFMT", SCM_MAKINUM (S_IFMT)); -#endif -#ifdef S_IFDIR - scm_sysintern ("S_IFDIR", SCM_MAKINUM (S_IFDIR)); -#endif -#ifdef S_IFCHR - scm_sysintern ("S_IFCHR", SCM_MAKINUM (S_IFCHR)); -#endif -#ifdef S_IFBLK - scm_sysintern ("S_IFBLK", SCM_MAKINUM (S_IFBLK)); -#endif -#ifdef S_IFREG - scm_sysintern ("S_IFREG", SCM_MAKINUM (S_IFREG)); -#endif -#ifdef S_IFLNK - scm_sysintern ("S_IFLNK", SCM_MAKINUM (S_IFLNK)); -#endif -#ifdef S_IFSOCK - scm_sysintern ("S_IFSOCK", SCM_MAKINUM (S_IFSOCK)); -#endif -#ifdef S_IFIFO - scm_sysintern ("S_IFIFO", SCM_MAKINUM (S_IFIFO)); -#endif #include "ioext.x" } diff --git a/libguile/posix.c b/libguile/posix.c index 42657faf5..a7a19b742 100644 --- a/libguile/posix.c +++ b/libguile/posix.c @@ -1214,10 +1214,6 @@ scm_init_posix () scm_sysintern ("WUNTRACED", SCM_MAKINUM (WUNTRACED)); #endif -#ifdef EINTR - scm_sysintern ("EINTR", SCM_MAKINUM (EINTR)); -#endif - #ifdef SIGHUP scm_sysintern ("SIGHUP", SCM_MAKINUM (SIGHUP)); #endif diff --git a/libguile/strop.c b/libguile/strop.c index cb658124c..bd1076a24 100644 --- a/libguile/strop.c +++ b/libguile/strop.c @@ -285,6 +285,53 @@ scm_string_fill_x (str, chr) return SCM_UNSPECIFIED; } +SCM_PROC(s_string_upcase_x, "string-upcase!", 1, 0, 0, scm_string_upcase_x); + +SCM +scm_string_upcase_x (v) + SCM v; +{ + register long k; + register unsigned char *cs; + SCM_ASRTGO (SCM_NIMP (v), badarg1); + k = SCM_LENGTH (v); + switch SCM_TYP7 + (v) + { + case scm_tc7_string: + cs = SCM_UCHARS (v); + while (k--) + cs[k] = scm_upcase(cs[k]); + break; + default: + badarg1:scm_wta (v, (char *) SCM_ARG1, s_string_upcase_x); + } + return v; +} + +SCM_PROC(s_string_downcase_x, "string-downcase!", 1, 0, 0, scm_string_downcase_x); + +SCM +scm_string_downcase_x (v) + SCM v; +{ + register long k; + register unsigned char *cs; + SCM_ASRTGO (SCM_NIMP (v), badarg1); + k = SCM_LENGTH (v); + switch SCM_TYP7 + (v) + { + case scm_tc7_string: + cs = SCM_UCHARS (v); + while (k--) + cs[k] = scm_downcase(cs[k]); + break; + default: + badarg1:scm_wta (v, (char *) SCM_ARG1, s_string_downcase_x); + } + return v; +} void diff --git a/libguile/strop.h b/libguile/strop.h index 091931aa1..a91812df2 100644 --- a/libguile/strop.h +++ b/libguile/strop.h @@ -2,7 +2,7 @@ #ifndef STROPH #define STROPH -/* Copyright (C) 1995,1996 Free Software Foundation, Inc. +/* Copyright (C) 1995,1996,1997 Free Software Foundation, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -59,5 +59,7 @@ extern SCM scm_string_to_list SCM_P ((SCM str)); extern SCM scm_string_copy SCM_P ((SCM str)); extern SCM scm_string_fill_x SCM_P ((SCM str, SCM chr)); extern void scm_init_strop SCM_P ((void)); +extern SCM scm_string_upcase_x SCM_P ((SCM v)); +extern SCM scm_string_downcase_x SCM_P ((SCM v)); #endif /* STROPH */ diff --git a/libguile/unif.c b/libguile/unif.c index c35230d47..a44e2c0f8 100644 --- a/libguile/unif.c +++ b/libguile/unif.c @@ -1925,56 +1925,6 @@ scm_bit_invert_x (v) } -SCM_PROC(s_string_upcase_x, "string-upcase!", 1, 0, 0, scm_string_upcase_x); - -SCM -scm_string_upcase_x (v) - SCM v; -{ - register long k; - register unsigned char *cs; - SCM_ASRTGO (SCM_NIMP (v), badarg1); - k = SCM_LENGTH (v); - switch SCM_TYP7 - (v) - { - case scm_tc7_string: - cs = SCM_UCHARS (v); - while (k--) - cs[k] = scm_upcase(cs[k]); - break; - default: - badarg1:scm_wta (v, (char *) SCM_ARG1, s_string_upcase_x); - } - return v; -} - -SCM_PROC(s_string_downcase_x, "string-downcase!", 1, 0, 0, scm_string_downcase_x); - -SCM -scm_string_downcase_x (v) - SCM v; -{ - register long k; - register unsigned char *cs; - SCM_ASRTGO (SCM_NIMP (v), badarg1); - k = SCM_LENGTH (v); - switch SCM_TYP7 - (v) - { - case scm_tc7_string: - cs = SCM_UCHARS (v); - while (k--) - cs[k] = scm_downcase(cs[k]); - break; - default: - badarg1:scm_wta (v, (char *) SCM_ARG1, s_string_downcase_x); - } - return v; -} - - - SCM scm_istr2bve (str, len) char *str; diff --git a/libguile/unif.h b/libguile/unif.h index bf44d8b72..a63da0cee 100644 --- a/libguile/unif.h +++ b/libguile/unif.h @@ -102,8 +102,6 @@ extern SCM scm_bit_position SCM_P ((SCM item, SCM v, SCM k)); extern SCM scm_bit_set_star_x SCM_P ((SCM v, SCM kv, SCM obj)); extern SCM scm_bit_count_star SCM_P ((SCM v, SCM kv, SCM obj)); extern SCM scm_bit_invert_x SCM_P ((SCM v)); -extern SCM scm_string_upcase_x SCM_P ((SCM v)); -extern SCM scm_string_downcase_x SCM_P ((SCM v)); extern SCM scm_istr2bve SCM_P ((char *str, long len)); extern SCM scm_array_to_list SCM_P ((SCM v)); extern SCM scm_list_to_uniform_array SCM_P ((SCM ndim, SCM prot, SCM lst));