tools.crossref: print message if there are no usages

db4
Slava Pestov 2009-09-23 22:50:26 -05:00
parent 4ec566b15d
commit 7012212708
1 changed files with 2 additions and 1 deletions
basis/tools/crossref

View File

@ -105,7 +105,8 @@ M: f smart-usage drop \ f smart-usage ;
synopsis-alist sort-keys definitions. ;
: usage. ( word -- )
smart-usage sorted-definitions. ;
smart-usage
[ "No usages." print ] [ sorted-definitions. ] if-empty ;
: vocab-xref ( vocab quot -- vocabs )
[ [ vocab-name ] [ words [ generic? not ] filter ] bi ] dip map