equal
deleted
inserted
replaced
307 fun mk_safe_if genuine_only none (cond, then_t, else_t) genuine = |
307 fun mk_safe_if genuine_only none (cond, then_t, else_t) genuine = |
308 let |
308 let |
309 val T = fastype_of then_t |
309 val T = fastype_of then_t |
310 val if_t = Const (@{const_name "If"}, @{typ bool} --> T --> T --> T) |
310 val if_t = Const (@{const_name "If"}, @{typ bool} --> T --> T --> T) |
311 in |
311 in |
312 Const (@{const_name "Quickcheck.catch_match"}, T --> T --> T) $ |
312 Const (@{const_name "Quickcheck_Random.catch_match"}, T --> T --> T) $ |
313 (if_t $ cond $ then_t $ else_t genuine) $ |
313 (if_t $ cond $ then_t $ else_t genuine) $ |
314 (if_t $ genuine_only $ none $ else_t false) |
314 (if_t $ genuine_only $ none $ else_t false) |
315 end |
315 end |
316 |
316 |
317 fun collect_results f [] results = results |
317 fun collect_results f [] results = results |