cleanup some lint warnings.
parent
e3e6e12c6a
commit
8c1165cac1
|
|
@ -65,7 +65,7 @@ SYMBOL: enter-out
|
|||
|
||||
: check-return ( word label -- )
|
||||
2dup
|
||||
[ stack-effect effect-height ]
|
||||
[ stack-height ]
|
||||
[ entry-stack-height current-stack-height swap - ]
|
||||
bi*
|
||||
= [ 2drop ] [
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ GENERIC: command-word ( command -- word )
|
|||
] H{ } make-assoc ;
|
||||
|
||||
: update-gestures ( class -- )
|
||||
dup command-gestures "gestures" set-word-prop ;
|
||||
dup command-gestures set-gestures ;
|
||||
|
||||
: define-command-map ( class group blurb pairs -- )
|
||||
<command-map>
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ TUPLE: pack < gadget
|
|||
|
||||
: round-dims ( seq -- newseq )
|
||||
[ { 0 0 } ] dip
|
||||
[ swap v- dup [ ceiling ] map [ swap v- ] keep ] map
|
||||
[ swap v- dup vceiling [ swap v- ] keep ] map
|
||||
nip ;
|
||||
|
||||
PRIVATE>
|
||||
|
|
|
|||
|
|
@ -35,5 +35,5 @@ M: polygon draw-interior
|
|||
tri ;
|
||||
|
||||
: <polygon-gadget> ( color points -- gadget )
|
||||
[ <polygon> ] [ { 0 0 } [ vmax ] reduce ] bi
|
||||
[ <polygon> ] [ max-dim ] bi
|
||||
[ <gadget> ] 2dip [ >>interior ] [ >>dim ] bi* ;
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ SLOT: model
|
|||
|
||||
: show-links-popup ( browser-gadget quot title -- )
|
||||
[ dup model>> ] 2dip <links-popup>
|
||||
[ hand-loc get { 0 0 } <rect> show-glass ] [ request-focus ] bi ; inline
|
||||
[ hand-loc get point>rect show-glass ] [ request-focus ] bi ; inline
|
||||
|
||||
: com-show-outgoing-links ( browser-gadget -- )
|
||||
[ uses ] "Outgoing links" show-links-popup ;
|
||||
|
|
|
|||
|
|
@ -171,7 +171,7 @@ PRIVATE>
|
|||
call( -- ) notify-ui-thread start-ui-thread ;
|
||||
|
||||
: ?attributes ( gadget title/attributes -- attributes )
|
||||
dup string? [ world-attributes new swap >>title ] [ clone ] if
|
||||
dup string? [ <world-attributes> swap >>title ] [ clone ] if
|
||||
swap [ [ [ 1array ] [ f ] if* ] curry unless* ] curry change-gadgets ;
|
||||
|
||||
PRIVATE>
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ M: effect clone
|
|||
[ in>> clone ] [ out>> clone ] bi <effect> ;
|
||||
|
||||
: stack-height ( word -- n )
|
||||
stack-effect effect-height ;
|
||||
stack-effect effect-height ; inline
|
||||
|
||||
: shuffle-mapping ( effect -- mapping )
|
||||
[ out>> ] [ in>> ] bi [ index ] curry map ;
|
||||
|
|
|
|||
|
|
@ -664,8 +664,7 @@ PRIVATE>
|
|||
|
||||
: prefix ( seq elt -- newseq )
|
||||
over [ over length 1 + ] dip [
|
||||
[ 0 swap set-nth-unsafe ] keep
|
||||
[ 1 swap copy ] keep
|
||||
(1sequence) [ 1 swap copy ] keep
|
||||
] new-like ;
|
||||
|
||||
: suffix ( seq elt -- newseq )
|
||||
|
|
|
|||
|
|
@ -27,6 +27,6 @@ IN: benchmark.dispatch2
|
|||
|
||||
: dispatch-test ( -- )
|
||||
1000000 sequences
|
||||
[ [ 0 swap nth don't-flush-me ] each ] curry times ;
|
||||
[ [ first don't-flush-me ] each ] curry times ;
|
||||
|
||||
MAIN: dispatch-test
|
||||
|
|
|
|||
|
|
@ -43,9 +43,6 @@ IN: ctags.etags
|
|||
1 - lines>bytes number>string %
|
||||
] "" make ;
|
||||
|
||||
: etag-length ( vector -- n )
|
||||
0 [ length + ] reduce ;
|
||||
|
||||
: (etag-header) ( n path -- str )
|
||||
[
|
||||
%
|
||||
|
|
@ -63,7 +60,7 @@ IN: ctags.etags
|
|||
[ first file>lines ]
|
||||
[ second ] bi
|
||||
[ etag ] with map
|
||||
dup etag-length
|
||||
dup sum-lengths
|
||||
] keep first
|
||||
etag-header append
|
||||
] each ;
|
||||
|
|
|
|||
Loading…
Reference in New Issue