help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Using comment characters for specific major modes


From: Jean Louis
Subject: Re: Using comment characters for specific major modes
Date: Sun, 6 Jun 2021 12:46:47 +0300
User-agent: Mutt/2.0.7+183 (3d24855) (2021-05-28)

* martin-kemp@brusseler.com <martin-kemp@brusseler.com> [2021-06-06 12:14]:
>    (let ((cm (cond ((eq major-mode 'emacs-lisp-mode) (do something))
>            ((eq major-mode 'texinfo-mode)    (do something))
>            ((eq major-mode 'f90-mode)        (do something))
>            ((eq major-mode 'fortran-mode)    (do something))
> 
> 
> 
> What I need is to set "cm" to ";;" for 'emacs-lisp-mode, "@c" for 
> texinfo-mode etc.
> Have difficulty setting "cm" though.

(setq cm ";;")

so you have to replace (do something) with the code you need.


-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

Sign an open letter in support of Richard M. Stallman
https://stallmansupport.org/



reply via email to

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