From bug-octave-request at bevo dot che dot wisc dot edu Mon Jan 24 20:28:18 2000 Subject: Bug in Octave major-mode for Emacs From: "John W. Eaton" To: Giuseppe Modugno Cc: bug-octave at bevo dot che dot wisc dot edu Date: Mon, 24 Jan 2000 20:28:31 -0600 (CST) On 24-Jan-2000, Giuseppe Modugno wrote: | This isn't a really Octave's bug because it's related writing | program for Octave with Emacs. | I'm Italian and I write my comment in italian language: then I | deeply use the letter e in comment (that is for and in English). | But when I use syntax highlight the letter e is highlighted | (perhaps it's treated as the Neper number) in comment too. | I think that it's a little bug. | Sure, I wrote my program for Octave in Octave mode in Emacs. It took me a while to figure out what was causing the bug because you didn't say precisely how to reproduce it. My guess is that you see this problem when you are typing comments that start with `%', but not if they start with `#'. If that is not the case, then please provide a precise test case that I can use to reproduce the problem. I think the following change is appropriate. I don't know why `%' would have been defined as punctuation instead of as a comment starter, since it is not used in Octave for anything but starting comments. Thanks, jwe 2000-01-24 John W. Eaton * emacs/octave-mod.el (octave-mode-syntax-table): Make `%' a comment start character too. Index: octave-mod.el =================================================================== RCS file: /usr/local/cvsroot/octave/emacs/octave-mod.el,v retrieving revision 1.12 diff -u -r1.12 octave-mod.el --- octave-mod.el 1999/10/27 02:21:46 1.12 +++ octave-mod.el 2000/01/25 02:21:15 at @ -301,7 +301,7 @@ (modify-syntax-entry ?\" "\"" table) (modify-syntax-entry ?. "w" table) (modify-syntax-entry ?_ "w" table) - (modify-syntax-entry ?\% "." table) + (modify-syntax-entry ?\% "<" table) (modify-syntax-entry ?\# "<" table) (modify-syntax-entry ?\n ">" table) (setq octave-mode-syntax-table table))) ----------------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.che.wisc.edu/octave/octave.html How to fund new projects: http://www.che.wisc.edu/octave/funding.html Subscription information: http://www.che.wisc.edu/octave/archive.html -----------------------------------------------------------------------