From 0d689ed389c3b1c52e2aac254a0b1e5dc343c360 Mon Sep 17 00:00:00 2001 From: Tony Garnock-Jones Date: Wed, 19 Feb 2014 16:12:11 -0500 Subject: [PATCH] Add contract-profile-thunk --- pkgs/contract-profile/main.rkt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pkgs/contract-profile/main.rkt b/pkgs/contract-profile/main.rkt index 238d6b591c..2e811491d4 100644 --- a/pkgs/contract-profile/main.rkt +++ b/pkgs/contract-profile/main.rkt @@ -222,7 +222,8 @@ ;;--------------------------------------------------------------------------- ;; Entry point -(provide (rename-out [contract-profile/user contract-profile])) +(provide (rename-out [contract-profile/user contract-profile]) + contract-profile-thunk) ;; TODO have kw args for profiler, etc. ;; TODO have kw args for output files @@ -237,3 +238,7 @@ (for/list ([s (in-list (sampler 'get-custom-snapshots))]) (and (not (empty? s)) (vector-ref (car s) 0)))) (analyze-contract-samples contract-samples samples))))) + +;; TODO: document +(define (contract-profile-thunk f) + (contract-profile/user (f)))