From 719ada1baae17854958dc10824e3e01938266c40 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 15 Nov 2012 05:06:07 -0700 Subject: [PATCH] fix benchmark on empty input --- collects/tests/racket/benchmarks/shootout/k-nucleotide.rkt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/collects/tests/racket/benchmarks/shootout/k-nucleotide.rkt b/collects/tests/racket/benchmarks/shootout/k-nucleotide.rkt index 61ea67dcfa..179a506743 100644 --- a/collects/tests/racket/benchmarks/shootout/k-nucleotide.rkt +++ b/collects/tests/racket/benchmarks/shootout/k-nucleotide.rkt @@ -25,7 +25,7 @@ (real->decimal-string (* 100 (/ (cdr a) total)) 3))))) (define (write-one-freq table key) - (let ([cnt (hash-ref table key 0)]) + (let ([cnt (hash-ref table key (box 0))]) (printf "~a\t~a\n" (unbox cnt) key))) (define dna