Fix Windows bootstrap
parent
917ff90fa1
commit
5edf8b0cb4
|
@ -123,7 +123,7 @@ SYMBOLS: +read-only+ +hidden+ +system+
|
||||||
+not-content-indexed+ +encrypted+ ;
|
+not-content-indexed+ +encrypted+ ;
|
||||||
|
|
||||||
: win32-file-attribute ( n attr symbol -- n )
|
: win32-file-attribute ( n attr symbol -- n )
|
||||||
>r dupd mask? [ r> , ] [ r> drop ] if ;
|
>r dupd mask? r> swap [ , ] [ drop ] if ;
|
||||||
|
|
||||||
: win32-file-attributes ( n -- seq )
|
: win32-file-attributes ( n -- seq )
|
||||||
[
|
[
|
||||||
|
|
|
@ -33,11 +33,9 @@ TUPLE: CreateProcess-args
|
||||||
CreateProcess-args >tuple< CreateProcess win32-error=0/f ;
|
CreateProcess-args >tuple< CreateProcess win32-error=0/f ;
|
||||||
|
|
||||||
: count-trailing-backslashes ( str n -- str n )
|
: count-trailing-backslashes ( str n -- str n )
|
||||||
>r "\\" ?tail [
|
>r "\\" ?tail r> swap [
|
||||||
r> 1+ count-trailing-backslashes
|
1+ count-trailing-backslashes
|
||||||
] [
|
] when ;
|
||||||
r>
|
|
||||||
] if ;
|
|
||||||
|
|
||||||
: fix-trailing-backslashes ( str -- str' )
|
: fix-trailing-backslashes ( str -- str' )
|
||||||
0 count-trailing-backslashes
|
0 count-trailing-backslashes
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
! Copyright (C) 2007 Doug Coleman.
|
! Copyright (C) 2007 Doug Coleman.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: kernel macros sequences slots words classes.tuple ;
|
USING: kernel macros sequences slots words classes.tuple
|
||||||
|
quotations combinators ;
|
||||||
IN: classes.tuple.lib
|
IN: classes.tuple.lib
|
||||||
|
|
||||||
: reader-slots ( seq -- quot )
|
: reader-slots ( seq -- quot )
|
||||||
[ slot-spec-reader ] map [ get-slots ] curry ;
|
[ slot-spec-reader 1quotation ] map [ cleave ] curry ;
|
||||||
|
|
||||||
MACRO: >tuple< ( class -- )
|
MACRO: >tuple< ( class -- )
|
||||||
all-slots rest-slice reader-slots ;
|
all-slots rest-slice reader-slots ;
|
||||||
|
|
Loading…
Reference in New Issue