From 8f969e9d91609d85ff73756c35cc9b56622c77c5 Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Thu, 8 May 2008 16:04:30 -0500 Subject: [PATCH] Clean up Ed's change --- extra/unix/unix.factor | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/extra/unix/unix.factor b/extra/unix/unix.factor index 38af4b8695..bc3e3ca162 100755 --- a/extra/unix/unix.factor +++ b/extra/unix/unix.factor @@ -80,14 +80,11 @@ FUNCTION: uint ntohl ( uint n ) ; FUNCTION: ushort ntohs ( ushort n ) ; FUNCTION: char* strerror ( int errno ) ; -TUPLE: open-error path flags prot message ; +ERROR: open-error path flags prot message ; : open ( path flags prot -- int ) - [ ] [ unix.ffi:open ] 3bi - dup 0 >= - [ nip nip nip ] - [ drop err_no strerror open-error boa throw ] - if ; + 3dup unix.ffi:open + dup 0 >= [ >r 3drop r> ] [ drop err_no strerror open-error ] if ; FUNCTION: int pclose ( void* file ) ; FUNCTION: int pipe ( int* filedes ) ; @@ -171,8 +168,6 @@ FUNCTION: int setpriority ( int which, int who, int prio ) ; FUNCTION: pid_t wait ( int* status ) ; FUNCTION: pid_t waitpid ( pid_t wpid, int* status, int options ) ; -! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - FUNCTION: ssize_t write ( int fd, void* buf, size_t nbytes ) ; {