]> gitweb.factorcode.org Git - factor.git/blobdiff - basis/lcs/lcs.factor
update existing code for [let change
[factor.git] / basis / lcs / lcs.factor
index aabd4bbafcd6e84d55d4dbb7e008e197b30ecf0d..38920f5764669daffbb2d6f07602de6dca37b27f 100644 (file)
@@ -25,11 +25,11 @@ IN: lcs
     [ [ + ] curry map ] with map ;\r
 \r
 :: run-lcs ( old new init step -- matrix )\r
-    [let | matrix [ old length 1 + new length 1 + init call ] |\r
-        old length [| i |\r
-            new length\r
-            [| j | i j matrix old new step loop-step ] each\r
-        ] each matrix ] ; inline\r
+    old length 1 + new length 1 + init call :> matrix\r
+    old length [| i |\r
+        new length\r
+        [| j | i j matrix old new step loop-step ] each\r
+    ] each matrix ; inline\r
 PRIVATE>\r
 \r
 : levenshtein ( old new -- n )\r