From 6f3d6ad5609d4c9d4557435eb3e71d1483966e4e Mon Sep 17 00:00:00 2001 From: John Benediktsson Date: Tue, 5 Aug 2014 11:41:22 -0700 Subject: [PATCH] tools.profiler.sampling: use formatting instead of math.parser.private. --- basis/tools/profiler/sampling/sampling.factor | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/basis/tools/profiler/sampling/sampling.factor b/basis/tools/profiler/sampling/sampling.factor index c8e93de388..d90efdaafe 100644 --- a/basis/tools/profiler/sampling/sampling.factor +++ b/basis/tools/profiler/sampling/sampling.factor @@ -1,10 +1,9 @@ ! (c)2011 Joe Groff bsd license -USING: accessors assocs combinators -combinators.short-circuit continuations fry generalizations -hashtables.identity io kernel kernel.private layouts locals -math math.parser math.parser.private math.statistics -math.vectors memory namespaces prettyprint sequences -sequences.generalizations sets sorting ; +USING: accessors assocs combinators combinators.short-circuit +continuations formatting fry generalizations hashtables.identity +io kernel kernel.private layouts locals math math.parser +math.statistics math.vectors memory namespaces prettyprint +sequences sequences.generalizations sets sorting ; FROM: sequences => change-nth ; FROM: assocs => change-at ; IN: tools.profiler.sampling @@ -201,10 +200,10 @@ PRIVATE> >alist [ second total-time>> ] inv-sort-with ; : duration. ( duration -- ) - 1000 * >float "%9.1f" format-float write ; + 1000 * "%9.1f" printf ; : percentage. ( num denom -- ) - [ 100 * ] dip /f "%6.2f" format-float write ; + [ 100 * ] dip /f "%6.2f" printf ; DEFER: (profile.)