Let's use the lisp-critic on the current file from Emacs.
Usage: M-x slime-critique-file
This is an ELisp function.
(defun slime-critique-file ()
"Lint this file with lisp-critic."
(interactive)
(slime-eval-async '(ql:quickload :lisp-critic))
(slime-eval-async
`(lisp-critic:critique-file ,(buffer-file-name))))
SLY version:
(defun sly-critique-file ()
"Lint this file with lisp-critic"
(interactive)
(sly-eval-async '(ql:quickload :lisp-critic))
(sly-eval-async
`(lisp-critic:critique-file ,(buffer-file-name))))
Example output in the CL repl:
(DEFUN F1 (ARG)
(PRINT "long and complex computation…")
(SLEEP 1)
(F0 (DECF ARG)))
----------------------------------------------------------------------
It's bad style to reassign input parameters like ARG -- and often
useless.
----------------------------------------------------------------------
In general, FORMAT is used for most printing, because it's more
flexible.
----------------------------------------------------------------------
thanks to @Gavinok on Discord.
Let's use the lisp-critic on the current file from Emacs.
Usage: M-x slime-critique-file
This is an ELisp function.
SLY version:
Example output in the CL repl:
thanks to @Gavinok on Discord.