unix: some using cleanups.

db4
John Benediktsson 2014-12-24 11:16:11 -08:00
parent 3f98ac4a30
commit 28ca2f5275
5 changed files with 11 additions and 16 deletions

View File

@ -1,7 +1,5 @@
USING: kernel alien.c-types alien.data alien.strings sequences USING: alien.c-types alien.data alien.syntax io.encodings.utf8
math alien.syntax unix namespaces continuations threads assocs kernel libc math sequences unix unix.types unix.utilities ;
io.backend.unix io.encodings.utf8 libc unix.types unix.utilities
fry unix.ffi ;
IN: unix.process IN: unix.process
! Low-level Unix process launching utilities. These are used ! Low-level Unix process launching utilities. These are used
@ -28,13 +26,13 @@ FUNCTION: int execve ( c-string path, c-string* argv, c-string* envp ) ;
[ utf8 strings>alien ] tri* execve ; [ utf8 strings>alien ] tri* execve ;
: exec-args ( seq -- int ) : exec-args ( seq -- int )
[ first ] [ ] bi exec ; [ first ] keep exec ;
: exec-args-with-path ( seq -- int ) : exec-args-with-path ( seq -- int )
[ first ] [ ] bi exec-with-path ; [ first ] keep exec-with-path ;
: exec-args-with-env ( seq seq -- int ) : exec-args-with-env ( seq seq -- int )
[ [ first ] [ ] bi ] dip exec-with-env ; [ [ first ] keep ] dip exec-with-env ;
: with-fork ( child parent -- ) : with-fork ( child parent -- )
[ fork-process ] 2dip if-zero ; inline [ fork-process ] 2dip if-zero ; inline

View File

@ -1,5 +1,5 @@
USING: alien.c-types arrays accessors combinators classes.struct USING: alien.c-types alien.syntax classes.struct unix.time
alien.syntax unix.time unix.types unix.ffi ; unix.types ;
IN: unix.stat IN: unix.stat
! Mac OS X ! Mac OS X

View File

@ -1,9 +1,7 @@
! Copyright (C) 2008 Doug Coleman. ! Copyright (C) 2008 Doug Coleman.
! See http://factorcode.org/license.txt for BSD license. ! See http://factorcode.org/license.txt for BSD license.
USING: alien.c-types io.encodings.utf8 io.encodings.string USING: alien.c-types alien.syntax classes.struct literals
kernel sequences unix.stat accessors unix combinators math unix.ffi unix.types ;
grouping system alien.strings math.bitwise alien.syntax
unix.types classes.struct unix.ffi literals ;
IN: unix.statfs.macosx IN: unix.statfs.macosx
CONSTANT: MNT_RDONLY 0x00000001 CONSTANT: MNT_RDONLY 0x00000001

View File

@ -1,6 +1,6 @@
USING: alien alien.c-types alien.enums alien.libraries USING: alien alien.c-types alien.enums alien.libraries
alien.syntax classes.struct combinators kernel math alien.syntax classes.struct combinators kernel math
system unix.types words ; system words ;
IN: curl.ffi IN: curl.ffi

View File

@ -1,8 +1,7 @@
! Copyright (C) 2014 Doug Coleman. ! Copyright (C) 2014 Doug Coleman.
! See http://factorcode.org/license.txt for BSD license. ! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.c-types alien.libraries USING: alien alien.c-types alien.libraries
alien.libraries.finder alien.syntax classes.struct kernel alien.libraries.finder alien.syntax classes.struct kernel ;
unix.types ;
IN: forestdb.ffi IN: forestdb.ffi
! Functions with LIBFDB_API are exported. ! Functions with LIBFDB_API are exported.