Move simple-table. to prettyprint since its generally useful and not specific to tools.time

db4
Slava Pestov 2008-11-04 17:23:08 -06:00
parent d8345b5eda
commit 22f11f24c9
2 changed files with 14 additions and 14 deletions

View File

@ -134,6 +134,20 @@ PRIVATE>
: pprint-cell ( obj -- ) [ pprint ] with-cell ;
: simple-table. ( values -- )
standard-table-style [
[
[
[
dup string?
[ [ write ] with-cell ]
[ pprint-cell ]
if
] each
] with-row
] each
] tabular-output ;
GENERIC: see ( defspec -- )
: comment. ( string -- )

View File

@ -7,20 +7,6 @@ IN: tools.time
: benchmark ( quot -- runtime )
millis >r call millis r> - ; inline
: simple-table. ( values -- )
standard-table-style [
[
[
[
dup string?
[ [ write ] with-cell ]
[ pprint-cell ]
if
] each
] with-row
] each
] tabular-output ;
: time. ( data -- )
unclip
"==== RUNNING TIME" print nl pprint " ms" print nl