diff options
Diffstat (limited to 'libguile/filesys.c')
-rw-r--r-- | libguile/filesys.c | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/libguile/filesys.c b/libguile/filesys.c index fa8cd18e1..dd2bec1fa 100644 --- a/libguile/filesys.c +++ b/libguile/filesys.c @@ -427,28 +427,28 @@ scm_stat2scm (struct stat *stat_temp) { SCM ans = scm_c_make_vector (15, SCM_UNSPECIFIED); - SCM_VECTOR_SET(ans, 0, scm_ulong2num ((unsigned long) stat_temp->st_dev)); - SCM_VECTOR_SET(ans, 1, scm_ulong2num ((unsigned long) stat_temp->st_ino)); - SCM_VECTOR_SET(ans, 2, scm_ulong2num ((unsigned long) stat_temp->st_mode)); - SCM_VECTOR_SET(ans, 3, scm_ulong2num ((unsigned long) stat_temp->st_nlink)); - SCM_VECTOR_SET(ans, 4, scm_ulong2num ((unsigned long) stat_temp->st_uid)); - SCM_VECTOR_SET(ans, 5, scm_ulong2num ((unsigned long) stat_temp->st_gid)); + SCM_VECTOR_SET(ans, 0, scm_from_ulong (stat_temp->st_dev)); + SCM_VECTOR_SET(ans, 1, scm_from_ulong (stat_temp->st_ino)); + SCM_VECTOR_SET(ans, 2, scm_from_ulong (stat_temp->st_mode)); + SCM_VECTOR_SET(ans, 3, scm_from_ulong (stat_temp->st_nlink)); + SCM_VECTOR_SET(ans, 4, scm_from_ulong (stat_temp->st_uid)); + SCM_VECTOR_SET(ans, 5, scm_from_ulong (stat_temp->st_gid)); #ifdef HAVE_STRUCT_STAT_ST_RDEV - SCM_VECTOR_SET(ans, 6, scm_ulong2num ((unsigned long) stat_temp->st_rdev)); + SCM_VECTOR_SET(ans, 6, scm_from_ulong (stat_temp->st_rdev)); #else SCM_VECTOR_SET(ans, 6, SCM_BOOL_F); #endif - SCM_VECTOR_SET(ans, 7, scm_ulong2num ((unsigned long) stat_temp->st_size)); - SCM_VECTOR_SET(ans, 8, scm_ulong2num ((unsigned long) stat_temp->st_atime)); - SCM_VECTOR_SET(ans, 9, scm_ulong2num ((unsigned long) stat_temp->st_mtime)); - SCM_VECTOR_SET(ans, 10, scm_ulong2num ((unsigned long) stat_temp->st_ctime)); + SCM_VECTOR_SET(ans, 7, scm_from_ulong (stat_temp->st_size)); + SCM_VECTOR_SET(ans, 8, scm_from_ulong (stat_temp->st_atime)); + SCM_VECTOR_SET(ans, 9, scm_from_ulong (stat_temp->st_mtime)); + SCM_VECTOR_SET(ans, 10, scm_from_ulong (stat_temp->st_ctime)); #ifdef HAVE_STRUCT_STAT_ST_BLKSIZE - SCM_VECTOR_SET(ans, 11, scm_ulong2num ((unsigned long) stat_temp->st_blksize)); + SCM_VECTOR_SET(ans, 11, scm_from_ulong (stat_temp->st_blksize)); #else - SCM_VECTOR_SET(ans, 11, scm_ulong2num (4096L)); + SCM_VECTOR_SET(ans, 11, scm_from_ulong (4096L)); #endif #ifdef HAVE_STRUCT_STAT_ST_BLOCKS - SCM_VECTOR_SET(ans, 12, scm_ulong2num ((unsigned long) stat_temp->st_blocks)); + SCM_VECTOR_SET(ans, 12, scm_from_ulong (stat_temp->st_blocks)); #else SCM_VECTOR_SET(ans, 12, SCM_BOOL_F); #endif @@ -1558,62 +1558,62 @@ scm_init_filesys () scm_dot_string = scm_permanent_object (scm_makfrom0str (".")); #ifdef O_RDONLY - scm_c_define ("O_RDONLY", scm_long2num (O_RDONLY)); + scm_c_define ("O_RDONLY", scm_from_long (O_RDONLY)); #endif #ifdef O_WRONLY - scm_c_define ("O_WRONLY", scm_long2num (O_WRONLY)); + scm_c_define ("O_WRONLY", scm_from_long (O_WRONLY)); #endif #ifdef O_RDWR - scm_c_define ("O_RDWR", scm_long2num (O_RDWR)); + scm_c_define ("O_RDWR", scm_from_long (O_RDWR)); #endif #ifdef O_CREAT - scm_c_define ("O_CREAT", scm_long2num (O_CREAT)); + scm_c_define ("O_CREAT", scm_from_long (O_CREAT)); #endif #ifdef O_EXCL - scm_c_define ("O_EXCL", scm_long2num (O_EXCL)); + scm_c_define ("O_EXCL", scm_from_long (O_EXCL)); #endif #ifdef O_NOCTTY - scm_c_define ("O_NOCTTY", scm_long2num (O_NOCTTY)); + scm_c_define ("O_NOCTTY", scm_from_long (O_NOCTTY)); #endif #ifdef O_TRUNC - scm_c_define ("O_TRUNC", scm_long2num (O_TRUNC)); + scm_c_define ("O_TRUNC", scm_from_long (O_TRUNC)); #endif #ifdef O_APPEND - scm_c_define ("O_APPEND", scm_long2num (O_APPEND)); + scm_c_define ("O_APPEND", scm_from_long (O_APPEND)); #endif #ifdef O_NONBLOCK - scm_c_define ("O_NONBLOCK", scm_long2num (O_NONBLOCK)); + scm_c_define ("O_NONBLOCK", scm_from_long (O_NONBLOCK)); #endif #ifdef O_NDELAY - scm_c_define ("O_NDELAY", scm_long2num (O_NDELAY)); + scm_c_define ("O_NDELAY", scm_from_long (O_NDELAY)); #endif #ifdef O_SYNC - scm_c_define ("O_SYNC", scm_long2num (O_SYNC)); + scm_c_define ("O_SYNC", scm_from_long (O_SYNC)); #endif #ifdef F_DUPFD - scm_c_define ("F_DUPFD", scm_long2num (F_DUPFD)); + scm_c_define ("F_DUPFD", scm_from_long (F_DUPFD)); #endif #ifdef F_GETFD - scm_c_define ("F_GETFD", scm_long2num (F_GETFD)); + scm_c_define ("F_GETFD", scm_from_long (F_GETFD)); #endif #ifdef F_SETFD - scm_c_define ("F_SETFD", scm_long2num (F_SETFD)); + scm_c_define ("F_SETFD", scm_from_long (F_SETFD)); #endif #ifdef F_GETFL - scm_c_define ("F_GETFL", scm_long2num (F_GETFL)); + scm_c_define ("F_GETFL", scm_from_long (F_GETFL)); #endif #ifdef F_SETFL - scm_c_define ("F_SETFL", scm_long2num (F_SETFL)); + scm_c_define ("F_SETFL", scm_from_long (F_SETFL)); #endif #ifdef F_GETOWN - scm_c_define ("F_GETOWN", scm_long2num (F_GETOWN)); + scm_c_define ("F_GETOWN", scm_from_long (F_GETOWN)); #endif #ifdef F_SETOWN - scm_c_define ("F_SETOWN", scm_long2num (F_SETOWN)); + scm_c_define ("F_SETOWN", scm_from_long (F_SETOWN)); #endif #ifdef FD_CLOEXEC - scm_c_define ("FD_CLOEXEC", scm_long2num (FD_CLOEXEC)); + scm_c_define ("FD_CLOEXEC", scm_from_long (FD_CLOEXEC)); #endif #include "libguile/filesys.x" |