indent based on subsequence of symbol

Lucien Pullen drurowin at gmail.com
Thu Oct 10 01:07:18 UTC 2013


I was wondering if it is possible to specify indentation rules for all
symbols that match a substring.

I have a macro that creates implicit MACROLET bodies for symbols
starting with "X!" (like DEFMACRO! from Let Over Lambda), and I'd like
them to be indented as LAMBDA.  So, something like:

  (defun/xml (item)
    (x!xsl/output
        (:method "xml"))
    (x!xsl/match (:name item)
      (x!name ()
        (x!xsl/value-of (:select "name")))))

Currently with slime-indentation, it gets indented as such:

  (defun/xml (item)
    (x!xsl/output
     (:method "xml"))
    (x!xsl/match (:name item)
                 (x!name ()
                         (x!xsl/value-of (:select "name")))))

The names of symbols will not be known beforehand, just that they start
with "X!".



More information about the slime-devel mailing list