src/HOL/Tools/Nitpick/nitpick_util.ML
changeset 54695 a9efdf970720
parent 54554 b8d0d8407c3b
child 54696 34496126a60c
--- a/src/HOL/Tools/Nitpick/nitpick_util.ML	Mon Dec 09 04:03:30 2013 +0100
+++ b/src/HOL/Tools/Nitpick/nitpick_util.ML	Mon Dec 09 04:03:30 2013 +0100
@@ -173,10 +173,8 @@
                                "indices unordered or out of range")
   in aux 0 js xs end
 
-fun cartesian_product [] _ = []
-  | cartesian_product (x :: xs) yss =
-    map (cons x) yss @ cartesian_product xs yss
-fun n_fold_cartesian_product xss = fold_rev cartesian_product xss [[]]
+fun n_fold_cartesian_product xss = Sledgehammer_Util.n_fold_cartesian_product
+
 fun all_distinct_unordered_pairs_of [] = []
   | all_distinct_unordered_pairs_of (x :: xs) =
     map (pair x) xs @ all_distinct_unordered_pairs_of xs