Quantcast
Viewing latest article 1
Browse Latest Browse All 2

Answer by db48x for Why having a system loaded makes any difference for indentation?

SLIME examines the argument list of macros to determine how to indent them correctly. Note that the indentation for the code supplied to the sera:and-let* macro went from being aligned with the first argument to being indented by two spaces from the macro name.

For reference, the macro is defined here: https://github.com/ruricolist/serapeum/blob/21b683a6969236f4b02066c1ce40a27cafbba512/binding.lisp#L266

Chapter 3.14 Semantic indentation of the SLIME manual says:

SLIME automatically discovers how to indent the macros in your Lispsystem. To do this the Lisp side scans all the macros in the systemand reports to Emacs all the ones with &body arguments. Emacs thenindents these specially, putting the first arguments four spaces inand the “body” arguments just two spaces, as usual.

If you don’t actually have your project’s system loaded into your lisp environment, then SLIME cannot do this, and it will simply assume that everything is a function and that all the args should be lined up vertically.


Viewing latest article 1
Browse Latest Browse All 2

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>