From: Marc Butler Date: 2001-04-30T11:14:07+09:00 Subject: [ruby-talk:14422] Problem colouring regexps in Emacs 20.7 I also encountered the problem where an escaped forward slash in a regular expression such as /\// cause a large portion of the script to be coloured like a string/regexp in GNU Emacs 20.7. [Ruby-talk 6002] I believe this patch fixes the problem. If other users could confirm this, it can be applied to misc/ruby-mode.el in the distribution. Thanks, Marc. (The patch starts on the line beginning with --- and was is unified diff format.) --- ../ruby-1.6.3/misc/ruby-mode.el Thu Feb 8 09:18:02 2001 +++ ruby-mode.el Sun Apr 29 17:54:35 2001 @@ -670,7 +670,7 @@ (setq font-lock-syntactic-keywords '(("\\$\\([#\"'`$\\]\\)" 1 (1 . nil)) ("\\(#\\)[{$@]" 1 (1 . nil)) - ("\\(/\\)\\([^/\n]\\|\\\\/\\)*\\(/\\)" + ("\\(/\\)\\([^/\n]\\|\\/\\)*\\(/\\)" (1 (7 . ?')) (3 (7 . ?'))))) (make-local-variable 'font-lock-defaults)