[Ecls-list] Improved readability of compiler messages

Juan Jose Garcia-Ripoll juanjose.garciaripoll at googlemail.com
Fri Feb 19 16:31:56 UTC 2010


- The code for handling and formatting compiler conditions is now
shared by the old and new compilers.
- Invocations of external programs are spaced by newlines
- At the beginning of COMPILE-FILE and also at the end, almost empty lines

;;
;;; Compiling foo.
;;; OPTIMIZE levels: Safety=2, Space=0, Speed=3, Debug=0
;;;
;;; Compiling (DEFUN A ...).
;;; End of Pass 1.
;;; Emitting code for A.
;;; Note:
;;;   Invoking external command:
;;;   gcc "-I/Users/jjgarcia/include/" -I/sw/include -g -O2 -fPIC
-fno-common  -Ddarwin -O -w -c "/Users/jjgarcia/build/ecl/foo.c" -o
"/Users/jjgarcia/build/ecl/foo.o"
;;;
;;; Note:
;;;   Invoking external command:
;;;   gcc -o "/Users/jjgarcia/build/ecl/foo.fas"
-L"/Users/jjgarcia/lib/" "/Users/jjgarcia/build/ecl/foo.o"   -bundle
-L/sw/lib -L/sw/lib  -lffi -lecl  -lgmp   -lm
;;;
;;; Finished compiling foo.
;;;

- Compiler warnings, notes and errors are now indented (see above and below)

;;; Emitting code for A.
;;; Error:
;;;   in file foo.lsp, position 0
;;;   at (DEFUN A ...)
;;;   * Wrong number of arguments for function COS

- When printing toplevel forms, only the innermost, not-macroexpanded
form is shown. The example above was compiled from

(progn
  (defun a (x)
    (cos x 2)))

- Compiler warnings carry the prefix #\!, compiler errors #\* and
notes have no per-line prefix.

Suggestions are welcome to improve this. Right now there is a minor
problem: the messages printed by the compiler may occupy a single
line. The reason is that prefixes are printed using ~@< ~:> instead of
~< ~> Please have a look at src/cmp/cmputil.lsp to see whether you can
improve this.

Juanjo

-- 
Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
http://juanjose.garciaripoll.googlepages.com




More information about the ecl-devel mailing list