]> gitweb.factorcode.org Git - factor.git/commitdiff
compiler.units: use ?adjoin.
authorJohn Benediktsson <mrjbq7@gmail.com>
Sun, 24 Mar 2013 05:13:14 +0000 (22:13 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sun, 24 Mar 2013 05:13:14 +0000 (22:13 -0700)
core/compiler/units/units.factor

index a35706697c04dccb9be7546432d81b561e723e5a..517ee50bfa9d9a793f2b31e90ccba1a06a3d2a3d 100644 (file)
@@ -19,7 +19,7 @@ TUPLE: redefine-error def ;
 <PRIVATE
 
 : add-once ( key set -- )
-    2dup in? [ over throw-redefine-error ] when adjoin ;
+    dupd ?adjoin [ drop ] [ throw-redefine-error ] if ;
 
 : (remember-definition) ( definition loc set -- )
     [ over set-where ] dip add-once ;