From a293b8a2c5ac362b9fa268ed32491dc340833fcc Mon Sep 17 00:00:00 2001 From: Eduardo Cavazos Date: Tue, 13 May 2008 13:32:55 -0500 Subject: [PATCH] unix.stat: Rename stat* and lstat*. Convert them to use 'unix-system-call'. --- extra/unix/stat/stat.factor | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/extra/unix/stat/stat.factor b/extra/unix/stat/stat.factor index cb1c939878..5864d33741 100644 --- a/extra/unix/stat/stat.factor +++ b/extra/unix/stat/stat.factor @@ -60,14 +60,12 @@ FUNCTION: int mkdir ( char* path, mode_t mode ) ; >> ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -: check-status ( n -- ) io-error ; +: file-status ( pathname -- stat ) + "stat" dup >r + [ stat ] unix-system-call drop + r> ; -: stat* ( pathname -- stat ) - "stat" dup >r - stat check-status - r> ; - -: lstat* ( pathname -- stat ) - "stat" dup >r - lstat check-status - r> ; +: link-status ( pathname -- stat ) + "stat" dup >r + [ lstat ] unix-system-call + r> ;