]> gitweb.factorcode.org Git - factor.git/commitdiff
core: use if* in a couple places.
authorJohn Benediktsson <mrjbq7@gmail.com>
Sun, 30 Nov 2014 00:03:50 +0000 (16:03 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sun, 30 Nov 2014 00:03:50 +0000 (16:03 -0800)
core/alien/alien.factor
core/words/words.factor

index 7d2c242b81f3fc5cb6b73a7765d18200fbc72794..2d5e071a3c59048fdb993b09a457dd794d9f150e 100755 (executable)
@@ -117,7 +117,7 @@ SYMBOL: callbacks
 TUPLE: expiry-check object alien ;
 
 : recompute-value? ( check -- ? )
-    dup [ alien>> expired? ] [ drop t ] if ;
+    [ alien>> expired? ] [ t ] if* ;
 
 : delete-values ( value assoc -- )
     [ rot drop = not ] with assoc-filter! drop ;
index d1cdd8b825d5c1c047ad7cd39a9f06c95d116886..8be802cde133e66916b55e8a664a3fd7e3e70b49 100644 (file)
@@ -212,12 +212,11 @@ ERROR: bad-create name vocab ;
 
 : create ( name vocab -- word )
     check-create 2dup lookup-word
-    dup [ 2nip ] [
-        drop
+    [ 2nip ] [
         vocab-name <word>
         dup reveal
         dup changed-definition
-    ] if ;
+    ] if* ;
 
 : constructor-word ( name vocab -- word )
     [ "<" ">" surround ] dip create ;