GNU bug report logs -
#21627
24.5; [generic-x]rul-generic-mode and font-lock bug
Previous Next
Reported by: rubikitch <rubikitch <at> ruby-lang.org>
Date: Tue, 6 Oct 2015 01:07:01 UTC
Severity: normal
Found in version 24.5
Done: Tom Tromey <tom <at> tromey.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your message dated Tue, 22 Dec 2015 16:56:08 -0700
with message-id <87lh8m2g2v.fsf <at> tromey.com>
and subject line fixed
has caused the debbugs.gnu.org bug report #21627,
regarding 24.5; [generic-x]rul-generic-mode and font-lock bug
to be marked as done.
(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)
--
21627: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=21627
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
Hi,
I found rul-generic-mode and font-lock bug.
==== test.el
(setq generic-extras-enable-list '(rul-generic-mode))
(require 'generic-x)
(find-library "files")
(find-file "/tmp/test.rul") ;empty file ok
(switch-to-buffer "files.el")
(emacs-lisp-mode)
====
$ emacs -Q -l test.el
Font-locking is incorrect in files.el.
I think because `font-lock-syntax-table' is not buffer-local.
I fixed it by advice.
====
(defun generic-rul-mode-setup-function--font-lock-bug-fix (&rest them)
(make-local-variable 'font-lock-syntax-table))
(advice-add 'generic-rul-mode-setup-function :before
'generic-rul-mode-setup-function--font-lock-bug-fix)
====
In GNU Emacs 24.5.1 (x86_64-unknown-linux-gnu, GNU/LessTif Version 2.1 Release 0.95.2)
of 2015-04-11 on yui
Windowing system distributor `The X.Org Foundation', version 11.0.11702000
System Description: Debian GNU/Linux testing (stretch)
Configured using:
`configure --disable-largefile --with-x-toolkit=motif
--without-toolkit-scroll-bars --without-xaw3d --without-xim
--without-compress-info --without-sound --without-pop
--without-sync-input --without-xpm --without-tiff --without-rsvg
--without-gconf --without-gsettings --without-selinux --without-gpm
--without-makeinfo --with-x 'CFLAGS=-march=corei7 -O2 -pipe''
Important settings:
value of $LC_ALL: ja_JP.utf8
value of $LC_CTYPE: ja_JP.utf8
value of $LANG: ja_JP.utf8
value of $XMODIFIERS: @im=skkinput
locale-coding-system: utf-8-unix
Cheers,
--
rubikitch
[Message part 3 (message/rfc822, inline)]
I checked in a fix for this on the emacs-25 branch.
Tom
This bug report was last modified 9 years and 151 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.