[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Indentation with inline comments in Emacs

From: Zelphir Kaltstahl
Subject: Indentation with inline comments in Emacs
Date: Sat, 16 Apr 2022 12:12:12 +0000

Hello Guile users!

The subject might not be only Guile related, but I figure, that many on this mailing list are using Emacs for writing Guile code. I wonder, if anyone has some trick for fixing the following indentation issue:

Sometimes I want to put inline comments with #||# in things like lists, arguments for function calls or vectors. For example I want to write the name of the month next to the number of days of that month, in a vector creation. Here is the example:

  #(#|January|# 31
                #|February|# 28
                             #|March|# 31 #|April|# 30 #|May|# 31 #|June|# 30 
#|July|# 31 #|August|# 30
                              30 30))

As you can see, the indentation is adjusted each line according to the non-comment thing on the previous line, when I press TAB or whatever other key binding one has for indentation. However, in this case I would rather want it to adjust indentation. Is there a quick fix for this? Or some way to make Emacs understand this as a separate case and have it indent "correctly"? Does anyone have a solution?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]