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

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

Re: font-lock in rexx-mode


From: Stefan Monnier
Subject: Re: font-lock in rexx-mode
Date: Sat, 09 Dec 2006 09:11:21 -0500
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux)

>> So if in Rexx a \ should not escape the
>> next char, the syntax-table should be changed.
>> Currently rexx-mode.el does:
>> 
>> (modify-syntax-entry ?\\ "\\" rexx-mode-syntax-table)
>> 
>> which as that \ should be treated as an escape char.  So either this
>> line is in error, or the \ should sometimes be treated as an escape
>> char and sometimes not.  I don't know anything about the syntax of
>> Rexx, so I have no idea when \ escapes and when it doesn't.  E.g. how
>> do you escape a " inside a string in Rexx?

> Thanks for the response.  I don't understand why, but commenting out the 
> above line and restarting emacs doesn't change the behavior.  (I do not 
> have a rexx-mode.elc.  If I start emacs with --no-init-file, rexx-mode is 
> not recognized.)

It's normal: this line is superfluous since it just repeats the default
setting of \.  Instead of removing it, you want to replace it with another
line such as

   (modify-syntax-entry ?\\ "." rexx-mode-syntax-table)

where the "." means "punctuation".  See C-h f modify-syntax-entry RET
for a bit more documentation.


        Stefan


reply via email to

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