unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* defining c-mode-syntax-table
@ 2022-02-17 16:38 Tim Johnson
  2022-02-17 18:35 ` Stefan Monnier via Users list for the GNU Emacs text editor
  0 siblings, 1 reply; 3+ messages in thread
From: Tim Johnson @ 2022-02-17 16:38 UTC (permalink / raw)
  To: MLEmacs

I have added the following line to init.el :
(modify-syntax-entry ?_ "w" c-mode-syntax-table)

When emacs loads, I get a warning that c-mode-syntax-table is not 
recognized,
but when I evaluate that sexp "by hand" it does evaluate without problem.

Could it be that there is a contingent dependency that is evaluated 
*after* the
  (modify-syntax-entry ?_ w c-mode-syntax-table) that defines 
modify-syntax-entry?

I would like to know so that I can move that code so that it follows 
said evaluation.

thanks

-- 
Tim
tj49.com




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: defining c-mode-syntax-table
  2022-02-17 16:38 defining c-mode-syntax-table Tim Johnson
@ 2022-02-17 18:35 ` Stefan Monnier via Users list for the GNU Emacs text editor
  2022-02-17 23:26   ` Tim Johnson
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier via Users list for the GNU Emacs text editor @ 2022-02-17 18:35 UTC (permalink / raw)
  To: help-gnu-emacs

> (modify-syntax-entry ?_ "w" c-mode-syntax-table)

FWIW, I think you want (superword-mode 1) instead.


        Stefan




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: defining c-mode-syntax-table
  2022-02-17 18:35 ` Stefan Monnier via Users list for the GNU Emacs text editor
@ 2022-02-17 23:26   ` Tim Johnson
  0 siblings, 0 replies; 3+ messages in thread
From: Tim Johnson @ 2022-02-17 23:26 UTC (permalink / raw)
  To: help-gnu-emacs



On 2/17/22 9:35 AM, Stefan Monnier via Users list for the GNU Emacs text 
editor wrote:
>> (modify-syntax-entry ?_ "w" c-mode-syntax-table)
> FWIW, I think you want (superword-mode 1) instead.
>
>
>          Stefan
Thank you for the reply, Stefan. Turns out that what I really needed 
(presumably) is

(require 'cc-mode)

cheers

-- 
Tim
tj49.com




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-02-17 23:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-02-17 16:38 defining c-mode-syntax-table Tim Johnson
2022-02-17 18:35 ` Stefan Monnier via Users list for the GNU Emacs text editor
2022-02-17 23:26   ` Tim Johnson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).