1 ! Copyright (C) 2009 Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: accessors assocs command-line compiler.errors debugger
4 io kernel namespaces sequences source-files.errors
5 source-files.errors.debugger summary ;
8 ! Tools for source-files.errors. Used by tools.tests and others
11 : errors. ( errors -- )
12 group-by-source-file sort-errors
14 [ nl "==== " write +listener-input+ or print nl ]
15 [ [ nl ] [ error. ] interleave ]
19 : :errors ( -- ) compiler-errors get values errors. ;
21 : :linkage ( -- ) linkage-errors get values errors. ;
23 : :user-init-errors ( -- )
24 user-init-errors get-global values errors. ;
26 M: not-compiled summary
27 word>> name>> "The word " " cannot be executed because it failed to compile" surround ;
29 M: not-compiled error.
30 [ summary print nl ] [ error>> error. ] bi ;