From a4a62524b3f853543c55a8531ff6667427bab2d1 Mon Sep 17 00:00:00 2001 From: John Benediktsson Date: Fri, 3 Aug 2012 09:37:01 -0700 Subject: [PATCH] benchmark.wrap: adding a wrap benchmark. --- extra/benchmark/wrap/wrap.factor | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 extra/benchmark/wrap/wrap.factor diff --git a/extra/benchmark/wrap/wrap.factor b/extra/benchmark/wrap/wrap.factor new file mode 100644 index 0000000000..7bd8d0335f --- /dev/null +++ b/extra/benchmark/wrap/wrap.factor @@ -0,0 +1,10 @@ +! Copyright (C) 2012 John Benediktsson +! See http://factorcode.org/license.txt for BSD license. +USING: kernel math math.parser sequences wrap wrap.strings ; +IN: benchmark.wrap + +: wrap-benchmark ( -- ) + 1,000 iota [ number>string ] map " " join + 100 [ dup 80 wrap-string drop ] times drop ; + +MAIN: wrap-benchmark