diff --git a/basis/io/backend/unix/unix.factor b/basis/io/backend/unix/unix.factor index 1797edccf6..39f0a5fec3 100644 --- a/basis/io/backend/unix/unix.factor +++ b/basis/io/backend/unix/unix.factor @@ -22,10 +22,6 @@ TUPLE: fd < disposable fd ; ] with-destructors ; : ( n -- fd ) - #! We drop the error code rather than calling io-error, - #! since on OS X 10.3, this operation fails from init-io - #! when running the Factor.app (presumably because fd 0 and - #! 1 are closed). fd new-disposable swap >>fd ; M: fd dispose @@ -197,5 +193,5 @@ TUPLE: mx-port < port mx ; [ drop 0 ] [ (io-error) ] if ] when ; -: ?flag ( n mask symbol -- n ) - pick rot bitand 0 > [ , ] [ drop ] if ; +:: ?flag ( n mask symbol -- n ) + n mask bitand 0 > [ symbol , ] when n ; diff --git a/basis/io/directories/unix/linux/linux.factor b/basis/io/directories/unix/linux/linux.factor index 932cbe230b..3d69c5f890 100644 --- a/basis/io/directories/unix/linux/linux.factor +++ b/basis/io/directories/unix/linux/linux.factor @@ -4,7 +4,7 @@ USING: alien.c-types io.directories.unix kernel system unix classes.struct unix.ffi ; IN: io.directories.unix.linux -M: unix find-next-file ( DIR* -- dirent ) +M: linux find-next-file ( DIR* -- dirent ) dirent f [ [ readdir64_r ] unix-system-call 0 = [ (io-error) ] unless ] 2keep diff --git a/basis/io/styles/styles.factor b/basis/io/styles/styles.factor index ae493be849..d4e1d2c557 100644 --- a/basis/io/styles/styles.factor +++ b/basis/io/styles/styles.factor @@ -163,9 +163,3 @@ M: input summary : write-object ( str obj -- ) presented associate format ; : write-image ( image -- ) [ "" ] dip image associate format ; - -SYMBOL: stack-effect-style -H{ - { foreground COLOR: FactorDarkGreen } - { font-style plain } -} stack-effect-style set-global diff --git a/basis/math/bitwise/bitwise.factor b/basis/math/bitwise/bitwise.factor index 204f295944..6b301fa97b 100644 --- a/basis/math/bitwise/bitwise.factor +++ b/basis/math/bitwise/bitwise.factor @@ -99,7 +99,7 @@ M: bignum (bit-count) ] if ; : byte-array-bit-count ( byte-array -- n ) - 0 [ byte-bit-count + ] reduce ; + 0 [ byte-bit-count + ] reduce ; inline PRIVATE> diff --git a/basis/prettyprint/stylesheet/stylesheet.factor b/basis/prettyprint/stylesheet/stylesheet.factor index 42a701d60f..bd25438b74 100644 --- a/basis/prettyprint/stylesheet/stylesheet.factor +++ b/basis/prettyprint/stylesheet/stylesheet.factor @@ -42,5 +42,12 @@ PRIVATE> : vocab-style ( vocab -- style ) dim-color colored-presentation-style ; +SYMBOL: stack-effect-style + +H{ + { foreground COLOR: FactorDarkGreen } + { font-style plain } +} stack-effect-style set-global + : effect-style ( effect -- style ) presented associate stack-effect-style get assoc-union ;