Hello,
This minor automatically lets you close block comment when typing a block comment start.
Thus…
typing /* in c-mode automatically inserts */. electric-block-comment-mode: on /*| ^ cursor /* | */ ^ cursor Or in lua --[[ inserts ]]--. electric-block-comment-mode: on --[[| ^ cursor --[[ | ]]-- ^ cursor
and so on.
However, there is a problem,
This minor mode uses block-comment-start
and block-comment-end
variables, which most of the major modes do not use or define.
The reason I decided to use these variables is because are more explicit with the type of comment that is used/supported.
I would like to hear your feedback.