# HG changeset patch # User bulwahn # Date 1311142596 -7200 # Node ID 13e6a4e702195f200f0fe26d116f02377d69790e # Parent a1da544e2652323221bb09bf612c5f9911452529 exporting function in quickcheck; adapting mutabelle script diff -r a1da544e2652 -r 13e6a4e70219 src/HOL/Mutabelle/lib/Tools/mutabelle --- a/src/HOL/Mutabelle/lib/Tools/mutabelle Wed Jul 20 08:16:35 2011 +0200 +++ b/src/HOL/Mutabelle/lib/Tools/mutabelle Wed Jul 20 08:16:36 2011 +0200 @@ -85,11 +85,11 @@ ML {* val mtds = [ - MutabelleExtra.quickcheck_mtd (Config.put Quickcheck.tester \"random\") \"random\", - MutabelleExtra.quickcheck_mtd (Config.put Quickcheck.tester \"exhaustive\") \"exhaustive\", - MutabelleExtra.quickcheck_mtd (Config.put Quickcheck.tester \"exhaustive\" #> Config.put Quickcheck.finite_types false) \"exhaustive_nft\", - MutabelleExtra.quickcheck_mtd (Config.put Quickcheck.tester \"narrowing\" #> Config.put Quickcheck.finite_types false) \"narrowing\", - MutabelleExtra.quickcheck_mtd (Config.put Quickcheck.tester \"narrowing\" #> Config.put Quickcheck.finite_types false + MutabelleExtra.quickcheck_mtd (Context.proof_map (Quickcheck.set_active_testers [\"random\"])) \"random\", + MutabelleExtra.quickcheck_mtd (Context.proof_map (Quickcheck.set_active_testers [\"exhaustive\"])) \"exhaustive\", + MutabelleExtra.quickcheck_mtd (Context.proof_map (Quickcheck.set_active_testers [\"exhaustive\"]) #> Config.put Quickcheck.finite_types false) \"exhaustive_nft\", + MutabelleExtra.quickcheck_mtd (Context.proof_map (Quickcheck.set_active_testers [\"narrowing\"]) #> Config.put Quickcheck.finite_types false) \"narrowing\", + MutabelleExtra.quickcheck_mtd (Context.proof_map (Quickcheck.set_active_testers [\"narrowing\"]) #> Config.put Quickcheck.finite_types false #> Context.proof_map (Quickcheck.map_test_params (apfst (K [@{typ nat}])))) \"narrowing_nat\" (* MutabelleExtra.nitpick_mtd *) ] diff -r a1da544e2652 -r 13e6a4e70219 src/Tools/quickcheck.ML --- a/src/Tools/quickcheck.ML Wed Jul 20 08:16:35 2011 +0200 +++ b/src/Tools/quickcheck.ML Wed Jul 20 08:16:36 2011 +0200 @@ -23,6 +23,7 @@ val timeout : real Config.T val finite_types : bool Config.T val finite_type_size : int Config.T + val set_active_testers: string list -> Context.generic -> Context.generic datatype expectation = No_Expectation | No_Counterexample | Counterexample; datatype test_params = Test_Params of {default_type: typ list, expect : expectation}; val test_params_of : Proof.context -> test_params